# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2024"
name = "nu-lint"
version = "0.1.3"
authors = ["Willem Vanhulle <willemvanhulle@protonmail.com>"]
build = "build.rs"
exclude = [
    "result",
    ".helix/",
    ".vscode/",
    ".github/",
    "Cargo.lock",
    "benches/",
]
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Linter for Nu shell scripts that helpfully suggests improvements"
readme = "README.md"
keywords = [
    "nushell",
    "linter",
    "static-analysis",
    "code-quality",
    "shell",
]
license = "MIT"
repository = "https://codeberg.org/wvhulle/nu-lint"

[package.metadata.binstall]
bin-dir = "nu-lint"
pkg-fmt = "tgz"
pkg-url = "{ repo }/releases/download/v{ version }/nu-lint-{ target }.tar.gz"

[features]
default = ["lsp"]
lsp = [
    "lsp-server",
    "lsp-types",
    "tracing-appender",
]

[lib]
name = "nu_lint"
path = "src/lib.rs"

[[bin]]
name = "nu-lint"
path = "src/main.rs"

[dependencies.clap]
version = "4.5"
features = ["derive"]

[dependencies.dirs]
version = "6"

[dependencies.heck]
version = "0.5"

[dependencies.ignore]
version = "0.4"

[dependencies.jaq-core]
version = "2.2"

[dependencies.log]
version = "0.4"

[dependencies.lsp-server]
version = "0.7"
optional = true

[dependencies.lsp-types]
version = "0.97"
optional = true

[dependencies.miette]
version = "7.6"
features = ["fancy"]

[dependencies.nu-cli]
version = "0.110.0"

[dependencies.nu-cmd-extra]
version = "0.110.0"

[dependencies.nu-cmd-lang]
version = "0.110.0"

[dependencies.nu-command]
version = "0.110.0"
features = ["sqlite"]

[dependencies.nu-parser]
version = "0.110.0"

[dependencies.nu-protocol]
version = "0.110.0"

[dependencies.nu-std]
version = "0.110.0"

[dependencies.owo-colors]
version = "4"

[dependencies.rayon]
version = "1.10"

[dependencies.regex]
version = "1.10"

[dependencies.serde]
version = "1.0"
features = ["derive"]

[dependencies.serde_json]
version = "1.0"

[dependencies.toml]
version = "0.8"

[dependencies.tracing]
version = "0.1"

[dependencies.tracing-appender]
version = "0.2"
optional = true

[dependencies.tracing-log]
version = "0.2"

[dependencies.tracing-subscriber]
version = "0.3"
features = ["env-filter"]

[dev-dependencies.criterion]
version = "0.7"
features = [
    "html_reports",
    "csv_output",
]

[dev-dependencies.nu-ansi-term]
version = "0.50"

[dev-dependencies.tempfile]
version = "3.10"

[build-dependencies.toml]
version = "0.8"

[lints.clippy]
absolute_paths = "warn"
allow_attributes_without_reason = "deny"
branches_sharing_code = "deny"
collapsible_else_if = "deny"
collapsible_if = "deny"
explicit_counter_loop = "deny"
explicit_iter_loop = "deny"
filter_map_next = "deny"
flat_map_identity = "deny"
get_unwrap = "deny"
if_then_some_else_none = "deny"
impl_trait_in_params = "allow"
manual_clamp = "deny"
manual_filter_map = "deny"
manual_find = "deny"
manual_map = "deny"
manual_ok_or = "deny"
manual_unwrap_or = "deny"
manual_while_let_some = "deny"
map_err_ignore = "deny"
map_flatten = "deny"
map_or_else = "allow"
map_unwrap_or = "deny"
match_bool = "deny"
missing_assert_message = "deny"
missing_const_for_fn = "deny"
missing_panics_doc = "allow"
multiple_inherent_impl = "deny"
mut_mut = "deny"
needless_bool = "deny"
needless_bool_assign = "deny"
needless_collect = "deny"
needless_continue = "deny"
needless_range_loop = "deny"
needless_raw_string_hashes = "allow"
option_if_let_else = "allow"
option_map_or_none = "deny"
panic_in_result_fn = "deny"
redundant_clone = "deny"
redundant_closure_for_method_calls = "deny"
redundant_pub_crate = "deny"
redundant_type_annotations = "deny"
renamed_function_params = "deny"
significant_drop_tightening = "deny"
single_match_else = "deny"
single_option_map = "deny"
struct_excessive_bools = "allow"
too_long_first_doc_paragraph = "deny"
trait_duplication_in_bounds = "deny"
trivial_regex = "deny"
type_repetition_in_bounds = "deny"
unnecessary_lazy_evaluations = "deny"
unnecessary_mut_passed = "deny"
use_self = "deny"
useless_let_if_seq = "deny"
verbose_file_reads = "deny"

[lints.clippy.complexity]
level = "warn"
priority = -1

[lints.clippy.pedantic]
level = "warn"
priority = -1

[lints.clippy.style]
level = "warn"
priority = -1
