pre-commit-hooks-nix

Configure pre-commit hooks.

Generates a configuration for pre-commit, provides a script to activate it, and adds a check.

Pre-defined hooks are maintained at cachix/pre-commit-hooks.nix.

Installation

To use these options, add to your flake inputs:

pre-commit-hooks-nix.url = "github:cachix/pre-commit-hooks.nix";

and inside the mkFlake:

imports = [
  inputs.pre-commit-hooks-nix.flakeModule
];

Run nix flake lock and you're set.

Options

perSystem.pre-commit.check.enable

perSystem.pre-commit.devShell

perSystem.pre-commit.installationScript

perSystem.pre-commit.pkgs

perSystem.pre-commit.settings

perSystem.pre-commit.settings.package

perSystem.pre-commit.settings.default_stages

perSystem.pre-commit.settings.excludes

perSystem.pre-commit.settings.hooks

perSystem.pre-commit.settings.hooks.<name>.enable

perSystem.pre-commit.settings.hooks.<name>.always_run

perSystem.pre-commit.settings.hooks.<name>.description

perSystem.pre-commit.settings.hooks.<name>.entry

perSystem.pre-commit.settings.hooks.<name>.excludes

perSystem.pre-commit.settings.hooks.<name>.fail_fast

perSystem.pre-commit.settings.hooks.<name>.files

perSystem.pre-commit.settings.hooks.<name>.language

perSystem.pre-commit.settings.hooks.<name>.name

perSystem.pre-commit.settings.hooks.<name>.pass_filenames

perSystem.pre-commit.settings.hooks.<name>.raw

perSystem.pre-commit.settings.hooks.<name>.require_serial

perSystem.pre-commit.settings.hooks.<name>.stages

perSystem.pre-commit.settings.hooks.<name>.types

perSystem.pre-commit.settings.hooks.<name>.types_or

perSystem.pre-commit.settings.hooks.<name>.verbose

perSystem.pre-commit.settings.installationScript

perSystem.pre-commit.settings.rootSrc

perSystem.pre-commit.settings.run

perSystem.pre-commit.settings.settings.alejandra.package

perSystem.pre-commit.settings.settings.alejandra.check

perSystem.pre-commit.settings.settings.alejandra.exclude

perSystem.pre-commit.settings.settings.alejandra.threads

perSystem.pre-commit.settings.settings.alejandra.verbosity

perSystem.pre-commit.settings.settings.ansible-lint.configPath

perSystem.pre-commit.settings.settings.ansible-lint.subdir

perSystem.pre-commit.settings.settings.autoflake.binPath

perSystem.pre-commit.settings.settings.autoflake.flags

perSystem.pre-commit.settings.settings.clippy.allFeatures

perSystem.pre-commit.settings.settings.clippy.denyWarnings

perSystem.pre-commit.settings.settings.clippy.offline

perSystem.pre-commit.settings.settings.cmake-format.configPath

perSystem.pre-commit.settings.settings.credo.strict

perSystem.pre-commit.settings.settings.deadnix.edit

perSystem.pre-commit.settings.settings.deadnix.exclude

perSystem.pre-commit.settings.settings.deadnix.hidden

perSystem.pre-commit.settings.settings.deadnix.noLambdaArg

perSystem.pre-commit.settings.settings.deadnix.noLambdaPatternNames

perSystem.pre-commit.settings.settings.deadnix.noUnderscore

perSystem.pre-commit.settings.settings.deadnix.quiet

perSystem.pre-commit.settings.settings.denofmt.configPath

perSystem.pre-commit.settings.settings.denofmt.write

perSystem.pre-commit.settings.settings.denolint.configPath

perSystem.pre-commit.settings.settings.denolint.format

perSystem.pre-commit.settings.settings.dune-fmt.auto-promote

perSystem.pre-commit.settings.settings.dune-fmt.extraRuntimeInputs

perSystem.pre-commit.settings.settings.eclint.package

perSystem.pre-commit.settings.settings.eclint.color

perSystem.pre-commit.settings.settings.eclint.exclude

perSystem.pre-commit.settings.settings.eclint.fix

perSystem.pre-commit.settings.settings.eclint.summary

perSystem.pre-commit.settings.settings.eclint.verbosity

perSystem.pre-commit.settings.settings.eslint.binPath

perSystem.pre-commit.settings.settings.eslint.extensions

perSystem.pre-commit.settings.settings.flake8.binPath

perSystem.pre-commit.settings.settings.flake8.extendIgnore

perSystem.pre-commit.settings.settings.flake8.format

perSystem.pre-commit.settings.settings.flynt.package

perSystem.pre-commit.settings.settings.flynt.aggressive

perSystem.pre-commit.settings.settings.flynt.binPath

perSystem.pre-commit.settings.settings.flynt.dry-run

perSystem.pre-commit.settings.settings.flynt.exclude

perSystem.pre-commit.settings.settings.flynt.fail-on-change

perSystem.pre-commit.settings.settings.flynt.line-length

perSystem.pre-commit.settings.settings.flynt.no-multiline

perSystem.pre-commit.settings.settings.flynt.quiet

perSystem.pre-commit.settings.settings.flynt.string

perSystem.pre-commit.settings.settings.flynt.transform-concats

perSystem.pre-commit.settings.settings.flynt.verbose

perSystem.pre-commit.settings.settings.headache.header-file

perSystem.pre-commit.settings.settings.hlint.hintFile

perSystem.pre-commit.settings.settings.hpack.silent

perSystem.pre-commit.settings.settings.isort.flags

perSystem.pre-commit.settings.settings.isort.profile

perSystem.pre-commit.settings.settings.latexindent.flags

perSystem.pre-commit.settings.settings.lua-ls.checklevel

perSystem.pre-commit.settings.settings.lua-ls.config

perSystem.pre-commit.settings.settings.lychee.configPath

perSystem.pre-commit.settings.settings.lychee.flags

perSystem.pre-commit.settings.settings.markdownlint.config

perSystem.pre-commit.settings.settings.mdl.package

perSystem.pre-commit.settings.settings.mdl.configPath

perSystem.pre-commit.settings.settings.mdl.git-recurse

perSystem.pre-commit.settings.settings.mdl.ignore-front-matter

perSystem.pre-commit.settings.settings.mdl.json

perSystem.pre-commit.settings.settings.mdl.rules

perSystem.pre-commit.settings.settings.mdl.rulesets

perSystem.pre-commit.settings.settings.mdl.show-aliases

perSystem.pre-commit.settings.settings.mdl.skip-default-ruleset

perSystem.pre-commit.settings.settings.mdl.style

perSystem.pre-commit.settings.settings.mdl.tags

perSystem.pre-commit.settings.settings.mdl.verbose

perSystem.pre-commit.settings.settings.mdl.warnings

perSystem.pre-commit.settings.settings.mkdocs-linkcheck.binPath

perSystem.pre-commit.settings.settings.mkdocs-linkcheck.extension

perSystem.pre-commit.settings.settings.mkdocs-linkcheck.local-only

perSystem.pre-commit.settings.settings.mkdocs-linkcheck.method

perSystem.pre-commit.settings.settings.mkdocs-linkcheck.path

perSystem.pre-commit.settings.settings.mkdocs-linkcheck.recurse

perSystem.pre-commit.settings.settings.mypy.binPath

perSystem.pre-commit.settings.settings.nixfmt.width

perSystem.pre-commit.settings.settings.ormolu.cabalDefaultExtensions

perSystem.pre-commit.settings.settings.ormolu.defaultExtensions

perSystem.pre-commit.settings.settings.php-cs-fixer.binPath

perSystem.pre-commit.settings.settings.phpcbf.binPath

perSystem.pre-commit.settings.settings.phpcs.binPath

perSystem.pre-commit.settings.settings.phpstan.binPath

perSystem.pre-commit.settings.settings.prettier.allow-parens

perSystem.pre-commit.settings.settings.prettier.binPath

perSystem.pre-commit.settings.settings.prettier.bracket-same-line

perSystem.pre-commit.settings.settings.prettier.cache

perSystem.pre-commit.settings.settings.prettier.cache-location

perSystem.pre-commit.settings.settings.prettier.cache-strategy

perSystem.pre-commit.settings.settings.prettier.check

perSystem.pre-commit.settings.settings.prettier.color

perSystem.pre-commit.settings.settings.prettier.config-precedence

perSystem.pre-commit.settings.settings.prettier.configPath

perSystem.pre-commit.settings.settings.prettier.embedded-language-formatting

perSystem.pre-commit.settings.settings.prettier.end-of-line

perSystem.pre-commit.settings.settings.prettier.html-whitespace-sensitivity

perSystem.pre-commit.settings.settings.prettier.ignore-path

perSystem.pre-commit.settings.settings.prettier.ignore-unknown

perSystem.pre-commit.settings.settings.prettier.insert-pragma

perSystem.pre-commit.settings.settings.prettier.jsx-single-quote

perSystem.pre-commit.settings.settings.prettier.list-different

perSystem.pre-commit.settings.settings.prettier.log-level

perSystem.pre-commit.settings.settings.prettier.no-bracket-spacing

perSystem.pre-commit.settings.settings.prettier.no-config

perSystem.pre-commit.settings.settings.prettier.no-editorconfig

perSystem.pre-commit.settings.settings.prettier.no-error-on-unmatched-pattern

perSystem.pre-commit.settings.settings.prettier.no-semi

perSystem.pre-commit.settings.settings.prettier.parser

perSystem.pre-commit.settings.settings.prettier.plugins

perSystem.pre-commit.settings.settings.prettier.print-width

perSystem.pre-commit.settings.settings.prettier.prose-wrap

perSystem.pre-commit.settings.settings.prettier.quote-props

perSystem.pre-commit.settings.settings.prettier.require-pragma

perSystem.pre-commit.settings.settings.prettier.single-attribute-per-line

perSystem.pre-commit.settings.settings.prettier.single-quote

perSystem.pre-commit.settings.settings.prettier.tab-width

perSystem.pre-commit.settings.settings.prettier.trailing-comma

perSystem.pre-commit.settings.settings.prettier.use-tabs

perSystem.pre-commit.settings.settings.prettier.vue-indent-script-and-style

perSystem.pre-commit.settings.settings.prettier.with-node-modules

perSystem.pre-commit.settings.settings.prettier.write

perSystem.pre-commit.settings.settings.psalm.binPath

perSystem.pre-commit.settings.settings.pylint.binPath

perSystem.pre-commit.settings.settings.pylint.reports

perSystem.pre-commit.settings.settings.pylint.score

perSystem.pre-commit.settings.settings.pyright.binPath

perSystem.pre-commit.settings.settings.pyupgrade.binPath

perSystem.pre-commit.settings.settings.revive.configPath

perSystem.pre-commit.settings.settings.rome.binPath

perSystem.pre-commit.settings.settings.rome.configPath

perSystem.pre-commit.settings.settings.rome.write

perSystem.pre-commit.settings.settings.rust.cargoManifestPath

perSystem.pre-commit.settings.settings.statix.format

perSystem.pre-commit.settings.settings.statix.ignore

perSystem.pre-commit.settings.settings.treefmt.package

perSystem.pre-commit.settings.settings.typos.binary

perSystem.pre-commit.settings.settings.typos.color

perSystem.pre-commit.settings.settings.typos.config

perSystem.pre-commit.settings.settings.typos.configPath

perSystem.pre-commit.settings.settings.typos.diff

perSystem.pre-commit.settings.settings.typos.exclude

perSystem.pre-commit.settings.settings.typos.format

perSystem.pre-commit.settings.settings.typos.hidden

perSystem.pre-commit.settings.settings.typos.ignored-words

perSystem.pre-commit.settings.settings.typos.locale

perSystem.pre-commit.settings.settings.typos.no-check-filenames

perSystem.pre-commit.settings.settings.typos.no-check-files

perSystem.pre-commit.settings.settings.typos.no-unicode

perSystem.pre-commit.settings.settings.typos.quiet

perSystem.pre-commit.settings.settings.typos.verbose

perSystem.pre-commit.settings.settings.typos.write

perSystem.pre-commit.settings.settings.vale.config

perSystem.pre-commit.settings.settings.vale.configPath

perSystem.pre-commit.settings.settings.vale.flags

perSystem.pre-commit.settings.settings.yamllint.configPath

perSystem.pre-commit.settings.settings.yamllint.relaxed

perSystem.pre-commit.settings.src

perSystem.pre-commit.settings.tools

perSystem.pre-commit.check.enable

Whether to add a derivation to the flake checks. It will perform the pre-commit checks in nix flake check.

You can disable this if one of your hooks do not run properly in the Nix sandbox; for example because it needs network access.

Type: boolean

Default: true

Declared by:

pre-commit-hooks-nix/flake-module.nix

perSystem.pre-commit.devShell

A development shell with pre-commit installed and setup.

Type: package (read only)

Declared by:

pre-commit-hooks-nix/flake-module.nix

perSystem.pre-commit.installationScript

A bash fragment that sets up pre-commit.

Type: string (read only)

Default: bash statements

Declared by:

pre-commit-hooks-nix/flake-module.nix

perSystem.pre-commit.pkgs

Nixpkgs to use in the pre-commit settings.

Type: lazy attribute set of raw value

Default: pkgs (module argument)

Declared by:

pre-commit-hooks-nix/flake-module.nix

perSystem.pre-commit.settings

The pre-commit-hooks.nix configuration.

Type: submodule

Default: { }

Declared by:

pre-commit-hooks-nix/flake-module.nix

perSystem.pre-commit.settings.package

The pre-commit package to use.

Type: package

Default:

pkgs.pre-commit

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.default_stages

A configuration wide option for the stages property. Installs hooks to the defined stages. See https://pre-commit.com/#confining-hooks-to-run-at-certain-stages.

Type: list of string

Default:

[
  "commit"
]

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.excludes

Exclude files that were matched by these patterns.

Type: list of string

Default: [ ]

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks

The hook definitions.

You can both specify your own hooks here and you can enable predefined hooks.

Example of enabling a predefined hook:

hooks.nixpkgs-fmt.enable = true;

Example of a custom hook:

hooks.my-tool = {
  enable = true;
  name = "my-tool";
  description = "Run MyTool on all files in the project";
  files = "\\.mtl$";
  entry = "${pkgs.my-tool}/bin/mytoolctl";
};

The predefined hooks are:

actionlint

Static checker for GitHub Actions workflow files.

alejandra

The Uncompromising Nix Code Formatter.

annex

Runs the git-annex hook for large file support

ansible-lint

Ansible linter.

autoflake

Remove unused imports and variables from Python code.

bats

Run bash unit tests.

beautysh

Format shell files.

black

The uncompromising Python code formatter.

cabal-fmt

Format Cabal files

cabal2nix

Run cabal2nix on all *.cabal files to generate corresponding default.nix files.

cargo-check

Check the cargo package for errors.

checkmake

Experimental linter/analyzer for Makefiles.

chktex

LaTeX semantic checker

clang-format

Format your code using clang-format.

clang-tidy

Static analyzer for C++ code.

clippy

Lint Rust code.

cljfmt

A tool for formatting Clojure code.

cmake-format

A tool for formatting CMake-files.

commitizen

Check whether the current commit message follows committing rules.

conform

Policy enforcement for commits.

convco

credo

Runs a static code analysis using Credo

crystal

A tool that automatically formats Crystal source code

cspell

A Spell Checker for Code

deadnix

Scan Nix files for dead code (unused variable bindings).

denofmt

Auto-format JavaScript, TypeScript, Markdown, and JSON files.

denolint

Lint JavaScript/TypeScript source code.

dhall-format

Dhall code formatter.

dialyzer

Runs a static code analysis using Dialyzer

dune-fmt

Runs Dune’s formatters on the code tree.

dune-opam-sync

Check that Dune-generated OPAM files are in sync.

eclint

EditorConfig linter written in Go.

editorconfig-checker

Verify that the files are in harmony with the .editorconfig.

elm-format

Format Elm files.

elm-review

Analyzes Elm projects, to help find mistakes before your users find them.

elm-test

Run unit tests and fuzz tests for Elm code.

eslint

Find and fix problems in your JavaScript code.

flake8

Check the style and quality of Python files.

flynt

CLI tool to convert a python project’s %-formatted strings to f-strings.

fourmolu

Haskell code prettifier.

fprettify

Auto-formatter for modern Fortran code.

gofmt

A tool that automatically formats Go source code

golangci-lint

Fast linters runner for Go.

gotest

Run go tests

govet

Checks correctness of Go programs.

gptcommit

Generate a commit message using GPT3.

hadolint

Dockerfile linter, validate inline bash.

headache

Lightweight tool for managing headers in source code files.

hindent

Haskell code prettifier.

hlint

HLint gives suggestions on how to improve your source code.

hpack

hpack converts package definitions in the hpack format (package.yaml) to Cabal files.

html-tidy

HTML linter.

hunspell

Spell checker and morphological analyzer.

isort

A Python utility / library to sort imports.

juliaformatter

Run JuliaFormatter.jl against Julia source files

latexindent

Perl script to add indentation to LaTeX files.

lua-ls

Uses the lua-language-server CLI to statically type-check and lint Lua code.

luacheck

A tool for linting and static analysis of Lua code.

lychee

A fast, async, stream-based link checker that finds broken hyperlinks and mail adresses inside Markdown, HTML, reStructuredText, or any other text file or website.

markdownlint

Style checker and linter for markdown files.

mdl

A tool to check markdown files and flag style issues.

mdsh

Markdown shell pre-processor.

mix-format

Runs the built-in Elixir syntax formatter

mix-test

Runs the built-in Elixir test framework

mkdocs-linkcheck

Validate links associated with markdown-based, statically generated websites.

mypy

Static type checker for Python

nil

Incremental analysis assistant for writing in Nix.

nixfmt

Nix code prettifier.

nixpkgs-fmt

Nix code prettifier.

ocp-indent

A tool to indent OCaml code.

opam-lint

OCaml package manager configuration checker.

ormolu

Haskell code prettifier.

php-cs-fixer

Lint PHP files.

phpcbf

Lint PHP files.

phpcs

Lint PHP files.

phpstan

Static Analysis of PHP files.

pre-commit-hook-ensure-sops

prettier

Opinionated multi-language code formatter.

psalm

Static Analysis of PHP files.

purs-tidy

Format purescript files.

purty

Format purescript files.

pylint

Lint Python files.

pyright

Static type checker for Python

pyupgrade

Automatically upgrade syntax for newer versions.

revive

A linter for Go source code.

rome

Unified developer tools for JavaScript, TypeScript, and the web

ruff

An extremely fast Python linter, written in Rust.

rustfmt

Format Rust code.

shellcheck

Format shell files.

shfmt

Format shell files.

staticcheck

State of the art linter for the Go programming language

statix

Lints and suggestions for the Nix programming language.

stylish-haskell

A simple Haskell code prettifier

stylua

An Opinionated Lua Code Formatter.

tagref

Have tagref check all references and tags.

taplo

Format TOML files with taplo fmt

terraform-format

Format terraform (.tf) files.

tflint

A Pluggable Terraform Linter.

topiary

A universal formatter engine within the Tree-sitter ecosystem, with support for many languages.

treefmt

One CLI to format the code tree.

typos

Source code spell checker

typstfmt

format typst

vale

A markup-aware linter for prose built with speed and extensibility in mind.

yamllint

Yaml linter.

zprint

Beautifully format Clojure and Clojurescript source code and s-expressions.

Type: attribute set of (submodule)

Default: { }

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.enable

Whether to enable this pre-commit hook.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.always_run

if true this hook will run even if there are no matching files.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.description

Description of the hook. used for metadata purposes only.

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.entry

The entry point - the executable to run. entry can also contain arguments that will not be overridden, such as entry = "autopep8 -i";.

Type: string

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.excludes

Exclude files that were matched by these patterns.

Type: list of string

Default: [ ]

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.fail_fast

if true pre-commit will stop running hooks if this hook fails.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.files

The pattern of files to run on.

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.language

The language of the hook - tells pre-commit how to install the hook.

Type: string

Default: "system"

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.name

The name of the hook - shown during hook execution.

Type: string

Default: internal name, same as id

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.pass_filenames

Whether to pass filenames as arguments to the entry point.

Type: boolean

Default: true

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.raw

Raw fields of a pre-commit hook. This is mostly for internal use but exposed in case you need to work around something.

Default: taken from the other hook options.

Type: attribute set of unspecified value

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.require_serial

if true this hook will execute using a single process instead of in parallel.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.stages

Confines the hook to run at a particular stage.

Type: list of string

Default: default_stages

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.types

List of file types to run on. See Filtering files with types.

Type: list of string

Default:

[
  "file"
]

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.types_or

List of file types to run on, where only a single type needs to match.

Type: list of string

Default: [ ]

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.hooks.<name>.verbose

forces the output of the hook to be printed even when the hook passes.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.installationScript

A bash snippet that installs nix-pre-commit-hooks in the current directory

Type: string (read only)

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.rootSrc

The source of the project to be checked.

This is used in the derivation that performs the check.

If you use the flakeModule, the default is self.outPath; the whole flake sources.

Type: path

Default: gitignoreSource config.src

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.run

A derivation that tests whether the pre-commit hooks run cleanly on the entire project.

Type: package (read only)

Default: "<derivation>"

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.settings.alejandra.package

The alejandra package to use.

Type: package

Default: "\${pkgs.alejandra}"

Example: "\${pkgs.alejandra}"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.alejandra.check

Check if the input is already formatted and disable writing in-place the modified content

Type: boolean

Default: false

Example: true

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.alejandra.exclude

Files or directories to exclude from formatting.

Type: list of string

Default: [ ]

Example:

[
  "flake.nix"
  "./templates"
]

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.alejandra.threads

Number of formatting threads to spawn.

Type: null or signed integer

Default: null

Example: 8

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.alejandra.verbosity

Whether informational messages or all messages should be hidden or not.

Type: one of “normal”, “quiet”, “silent”

Default: "normal"

Example: "quiet"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.ansible-lint.configPath

Path to the YAML configuration file.

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.ansible-lint.subdir

Path to the Ansible subdirectory.

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.autoflake.binPath

Path to autoflake binary.

Type: string

Default:

"${tools.autoflake}/bin/autoflake"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.autoflake.flags

Flags passed to autoflake.

Type: string

Default: "--in-place --expand-star-imports --remove-duplicate-keys --remove-unused-variables"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.clippy.allFeatures

Run clippy with --all-features

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.clippy.denyWarnings

Fail when warnings are present

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.clippy.offline

Run clippy offline

Type: boolean

Default: true

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.cmake-format.configPath

Path to the configuration file (.json,.python,.yaml)

Type: string

Default: ""

Example: ".cmake-format.json"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.credo.strict

Whether to auto-promote the changes.

Type: boolean

Default: true

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.deadnix.edit

Remove unused code and write to source file.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.deadnix.exclude

Files to exclude from analysis.

Type: list of string

Default: [ ]

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.deadnix.hidden

Recurse into hidden subdirectories and process hidden .*.nix files.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.deadnix.noLambdaArg

Don’t check lambda parameter arguments.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.deadnix.noLambdaPatternNames

Don’t check lambda pattern names (don’t break nixpkgs callPackage).

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.deadnix.noUnderscore

Don’t check any bindings that start with a _.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.deadnix.quiet

Don’t print a dead code report.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.denofmt.configPath

Path to the configuration JSON file

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.denofmt.write

Whether to edit files inplace.

Type: boolean

Default: true

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.denolint.configPath

Path to the configuration JSON file

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.denolint.format

Output format.

Type: one of “default”, “compact”, “json”

Default: "default"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.dune-fmt.auto-promote

Whether to auto-promote the changes.

Type: boolean

Default: true

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.dune-fmt.extraRuntimeInputs

Extra runtimeInputs to add to the environment, eg. ocamlformat.

Type: list of package

Default: [ ]

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.eclint.package

The eclint package to use.

Type: package

Default: ${tools.eclint}

Example: ${pkgs.eclint}

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.eclint.color

When to generate colored output.

Type: one of “auto”, “always”, “never”

Default: "auto"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.eclint.exclude

Filter to exclude files.

Type: list of string

Default: [ ]

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.eclint.fix

Modify files in place rather than showing the errors.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.eclint.summary

Only show number of errors per file.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.eclint.verbosity

Log level verbosity

Type: one of 0, 1, 2, 3, 4

Default: 0

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.eslint.binPath

eslint binary path. E.g. if you want to use the eslint in node_modules, use ./node_modules/.bin/eslint.

Type: path

Default: ${tools.eslint}/bin/eslint

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.eslint.extensions

The pattern of files to run on, see https://pre-commit.com/#hooks-files.

Type: string

Default: "\\.js$"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flake8.binPath

flake8 binary path. Should be used to specify flake8 binary from your Nix-managed Python environment.

Type: string

Default:

"${tools.flake8}/bin/flake8"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flake8.extendIgnore

List of additional ignore codes

Type: list of string

Default: [ ]

Example:

[
  "E501"
]

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flake8.format

Output format.

Type: string

Default: "default"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flynt.package

The flynt package to use.

Type: package

Default: "\${tools.flynt}"

Example: "\${pkgs.python310Packages.flynt}"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flynt.aggressive

Include conversions with potentially changed behavior.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flynt.binPath

flynt binary path. Can be used to specify the flynt binary from an existing Python environment.

Type: string

Default: "\${settings.flynt.package}/bin/flynt"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flynt.dry-run

Do not change files in-place and print diff instead.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flynt.exclude

Ignore files with given strings in their absolute path.

Type: list of string

Default: [ ]

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flynt.fail-on-change

Fail when diff is not empty (for linting purposes).

Type: boolean

Default: true

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flynt.line-length

Convert expressions spanning multiple lines, only if the resulting single line will fit into this line length limit.

Type: null or signed integer

Default: null

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flynt.no-multiline

Convert only single line expressions.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flynt.quiet

Run without output.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flynt.string

Interpret the input as a Python code snippet and print the converted version.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flynt.transform-concats

Replace string concatenations with f-strings.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.flynt.verbose

Run with verbose output.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.headache.header-file

Path to the header file.

Type: string

Default: ".header"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.hlint.hintFile

Path to hlint.yaml. By default, hlint searches for .hlint.yaml in the project root.

Type: null or path

Default: null

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.hpack.silent

Whether generation should be silent.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.isort.flags

Flags passed to isort. See all available here.

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.isort.profile

Built-in profiles to allow easy interoperability with common projects and code styles.

Type: one of “”, “black”, “django”, “pycharm”, “google”, “open_stack”, “plone”, “attrs”, “hug”, “wemake”, “appnexus”

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.latexindent.flags

Flags passed to latexindent. See available flags here

Type: string

Default: "--local --silent --overwriteIfDifferent"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.lua-ls.checklevel

The diagnostic check level

Type: one of “Error”, “Warning”, “Information”, “Hint”

Default: "Warning"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.lua-ls.config

See https://github.com/LuaLS/lua-language-server/wiki/Configuration-File#luarcjson

Type: attribute set

Default: { }

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.lychee.configPath

Path to the config file.

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.lychee.flags

Flags passed to lychee. See all available here.

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.markdownlint.config

See https://github.com/DavidAnson/markdownlint/blob/main/schema/.markdownlint.jsonc

Type: attribute set

Default: { }

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mdl.package

The mdl package to use.

Type: package

Default: "\${tools.mdl}"

Example: "\${pkgs.mdl}"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mdl.configPath

The configuration file to use.

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mdl.git-recurse

Only process files known to git when given a directory.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mdl.ignore-front-matter

Ignore YAML front matter.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mdl.json

Format output as JSON.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mdl.rules

Markdown rules to use for linting. Per default all rules are processed.

Type: list of string

Default: [ ]

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mdl.rulesets

Specify additional ruleset files to load.

Type: list of string

Default: [ ]

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mdl.show-aliases

Show rule alias instead of rule ID when viewing rules.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mdl.skip-default-ruleset

Do not load the default markdownlint ruleset. Use this option if you only want to load custom rulesets.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mdl.style

Select which style mdl uses.

Type: string

Default: "default"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mdl.tags

Markdown rules to use for linting containing the given tags. Per default all rules are processed.

Type: list of string

Default: [ ]

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mdl.verbose

Increase verbosity.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mdl.warnings

Show Kramdown warnings.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mkdocs-linkcheck.binPath

mkdocs-linkcheck binary path. Should be used to specify the mkdocs-linkcheck binary from your Nix-managed Python environment.

Type: path

Default:

"${tools.mkdocs-linkcheck}/bin/mkdocs-linkcheck"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mkdocs-linkcheck.extension

File extension to scan for.

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mkdocs-linkcheck.local-only

Whether to only check local links.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mkdocs-linkcheck.method

HTTP method to use when checking external links.

Type: one of “get”, “head”

Default: "get"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mkdocs-linkcheck.path

Path to check

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mkdocs-linkcheck.recurse

Whether to recurse directories under path.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.mypy.binPath

Mypy binary path. Should be used to specify the mypy executable in an environment containing your typing stubs.

Type: string

Default:

"${tools.mypy}/bin/mypy"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.nixfmt.width

Line width.

Type: null or signed integer

Default: null

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.ormolu.cabalDefaultExtensions

Use default-extensions from .cabal files.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.ormolu.defaultExtensions

Haskell language extensions to enable.

Type: list of string

Default: [ ]

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.php-cs-fixer.binPath

PHP-CS-Fixer binary path.

Type: string

Default:

"${tools.php-cs-fixer}/bin/php-cs-fixer"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.phpcbf.binPath

PHP_CodeSniffer binary path.

Type: string

Default:

"${tools.phpcbf}/bin/phpcbf"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.phpcs.binPath

PHP_CodeSniffer binary path.

Type: string

Default:

"${tools.phpcs}/bin/phpcs"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.phpstan.binPath

PHPStan binary path.

Type: string

Default:

"${tools.phpstan}/bin/phpstan"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.allow-parens

Include parentheses around a sole arrow function parameter.

Type: one of “always”, “avoid”

Default: "always"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.binPath

prettier binary path. E.g. if you want to use the prettier in node_modules, use ./node_modules/.bin/prettier.

Type: path

Default:

"${tools.prettier}/bin/prettier"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.bracket-same-line

Put > of opening tags on the last line instead of on a new line.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.cache

Only format changed files.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.cache-location

Path to the cache file location used by --cache flag.

Type: string

Default: "./node_modules/.cache/prettier/.prettier-cache"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.cache-strategy

Strategy for the cache to use for detecting changed files.

Type: null or one of “metadata”, “content”

Default: null

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.check

Output a human-friendly message and a list of unformatted files, if any.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.color

Colorize error messages.

Type: boolean

Default: true

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.config-precedence

Defines how config file should be evaluated in combination of CLI options.

Type: one of “cli-override”, “file-override”, “prefer-file”

Default: "cli-override"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.configPath

Path to a Prettier configuration file (.prettierrc, package.json, prettier.config.js).

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.embedded-language-formatting

Control how Prettier formats quoted code embedded in the file.

Type: one of “auto”, “off”

Default: "auto"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.end-of-line

Which end of line characters to apply.

Type: one of “lf”, “crlf”, “cr”, “auto”

Default: "lf"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.html-whitespace-sensitivity

How to handle whitespaces in HTML.

Type: one of “css”, “strict”, “ignore”

Default: "css"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.ignore-path

Path to a file containing patterns that describe files to ignore. By default, prettier looks for ./.gitignore and ./.prettierignore. Multiple values are accepted.

Type: list of path

Default: [ ]

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.ignore-unknown

Ignore unknown files.

Type: boolean

Default: true

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.insert-pragma

Insert @format pragma into file’s first docblock comment.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.jsx-single-quote

Use single quotes in JSX.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.list-different

Print the filenames of files that are different from Prettier formatting.

Type: boolean

Default: true

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.log-level

What level of logs to report.

Type: one of “silent”, “error”, “warn”, “log”, “debug”

Default: "log"

Example: "debug"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.no-bracket-spacing

Do not print spaces between brackets.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.no-config

Do not look for a configuration file.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.no-editorconfig

Don’t take .editorconfig into account when parsing configuration.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.no-error-on-unmatched-pattern

Prevent errors when pattern is unmatched.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.no-semi

Do not print semicolons, except at the beginning of lines which may need them.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.parser

Which parser to use.

Type: one of “”, “flow”, “babel”, “babel-flow”, “babel-ts”, “typescript”, “acorn”, “espree”, “meriyah”, “css”, “less”, “scss”, “json”, “json5”, “json-stringify”, “graphql”, “markdown”, “mdx”, “vue”, “yaml”, “glimmer”, “html”, “angular”, “lwc”

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.plugins

Add plugins from paths.

Type: list of string

Default: [ ]

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.print-width

Line length that the printer will wrap on.

Type: signed integer

Default: 80

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.prose-wrap

When to or if at all hard wrap prose to print width.

Type: one of “always”, “never”, “preserve”

Default: "preserve"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.quote-props

Change when properties in objects are quoted.

Type: one of “as-needed”, “consistent”, “preserve”

Default: "as-needed"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.require-pragma

Require either ‘@prettier’ or ‘@format’ to be present in the file’s first docblock comment.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.single-attribute-per-line

Enforce single attribute per line in HTML, Vue andJSX.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.single-quote

Number of spaces per indentation-level.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.tab-width

Line length that the printer will wrap on.

Type: signed integer

Default: 2

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.trailing-comma

Print trailing commas wherever possible in multi-line comma-separated syntactic structures.

Type: one of “all”, “es5”, “none”

Default: "all"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.use-tabs

Indent with tabs instead of spaces.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.vue-indent-script-and-style

Indent script and style tags in Vue files.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.with-node-modules

Process files inside ‘node_modules’ directory.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.prettier.write

Edit files in-place.

Type: boolean

Default: true

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.psalm.binPath

Psalm binary path.

Type: string

Default:

"${tools.psalm}/bin/psalm"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.pylint.binPath

Pylint binary path. Should be used to specify Pylint binary from your Nix-managed Python environment.

Type: string

Default:

"${tools.pylint}/bin/pylint"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.pylint.reports

Whether to display a full report.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.pylint.score

Whether to activate the evaluation score.

Type: boolean

Default: true

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.pyright.binPath

Pyright binary path. Should be used to specify the pyright executable in an environment containing your typing stubs.

Type: string

Default:

"${tools.pyright}/bin/pyright"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.pyupgrade.binPath

pyupgrade binary path. Should be used to specify the pyupgrade binary from your Nix-managed Python environment.

Type: string

Default:

"${tools.pyupgrade}/bin/pyupgrade"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.revive.configPath

Path to the configuration TOML file.

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.rome.binPath

rome binary path. E.g. if you want to use the rome in node_modules, use ./node_modules/.bin/rome.

Type: path

Default: "\${tools.biome}/bin/biome"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.rome.configPath

Path to the configuration JSON file

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.rome.write

Whether to edit files inplace.

Type: boolean

Default: true

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.rust.cargoManifestPath

Path to Cargo.toml

Type: null or string

Default: null

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.statix.format

Error Output format.

Type: one of “stderr”, “errfmt”, “json”

Default: "errfmt"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.statix.ignore

Globs of file patterns to skip.

Type: list of string

Default: [ ]

Example:

[
  "flake.nix"
  "_*"
]

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.treefmt.package

The treefmt package to use.

Should include all the formatters configured by treefmt.

For example:

pkgs.writeShellApplication {
  name = "treefmt";
  runtimeInputs = [
    pkgs.treefmt
    pkgs.nixpkgs-fmt
    pkgs.black
  ];
  text =
    ''
      exec treefmt "$@"
    '';
}

Type: package

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.binary

Whether to search binary files.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.color

When to use generate output.

Type: one of “auto”, “always”, “never”

Default: "auto"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.config

Multiline-string configuration passed as config file. If set, config set in typos.settings.configPath gets ignored.

Type: string

Default: ""

Example:

''
  [files]
  ignore-dot = true

[default] binary = false

[type.py] extend-glob = [] ''

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.configPath

Path to a custom config file.

Type: string

Default: ""

Example: ".typos.toml"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.diff

Print a diff of what would change.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.exclude

Ignore files and directories matching the glob.

Type: string

Default: ""

Example: "*.nix"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.format

Output format to use.

Type: one of “silent”, “brief”, “long”, “json”

Default: "long"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.hidden

Search hidden files and directories.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.ignored-words

Spellings and words to ignore.

Type: list of string

Default: [ ]

Example:

[
  "MQTT"
  "mosquitto"
]

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.locale

Which language to use for spell checking.

Type: one of “en”, “en-us”, “en-gb”, “en-ca”, “en-au”

Default: "en"

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.no-check-filenames

Skip verifying spelling in file names.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.no-check-files

Skip verifying spelling in files.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.no-unicode

Only allow ASCII characters in identifiers.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.quiet

Less output per occurence.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.verbose

More output per occurence.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.typos.write

Fix spelling in files by writing them. Cannot be used with typos.settings.diff.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.vale.config

Multiline-string configuration passed as config file.

Type: string

Default: ""

Example:

''
  MinAlertLevel = suggestion
  [*]
  BasedOnStyles = Vale
''

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.vale.configPath

Path to the config file.

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.vale.flags

Flags passed to vale.

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.yamllint.configPath

Path to the YAML configuration file.

Type: string

Default: ""

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.settings.yamllint.relaxed

Whether to use the relaxed configuration.

Type: boolean

Default: false

Declared by:

pre-commit-hooks-nix/modules/hooks.nix

perSystem.pre-commit.settings.src

Root of the project. By default this will be filtered with the gitignoreSource function later, unless rootSrc is specified.

If you use the flakeModule, the default is self.outPath; the whole flake sources.

Type: path

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix

perSystem.pre-commit.settings.tools

Tool set from which nix-pre-commit-hooks will pick binaries.

nix-pre-commit-hooks comes with its own set of packages for this purpose.

Type: lazy attribute set of (null or package)

Default: pre-commit-hooks.nix-pkgs.callPackage tools-dot-nix { inherit (pkgs) system; }

Declared by:

pre-commit-hooks-nix/modules/pre-commit.nix