Skip to content

Commit

Permalink
Merge pull request cachix#359 from dz0ny/add/eclint
Browse files Browse the repository at this point in the history
Add support for eclint
  • Loading branch information
domenkozar authored Oct 1, 2023
2 parents cb770e9 + d67283c commit 033453f
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 1 deletion.
18 changes: 18 additions & 0 deletions modules/hooks.nix
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,17 @@ in
default = "\\.js$";
};
};
eclint =
{
binPath =
mkOption {
type = types.path;
description = lib.mdDoc
"EditorConfig linter and formatter.";
default = "${tools.eclint}/bin/eclint";
defaultText = lib.literalExpression "\${tools.eclint}/bin/eclint";
};
};
rome =
{
binPath =
Expand Down Expand Up @@ -1485,6 +1496,13 @@ in
files = "${settings.eslint.extensions}";
};

eclint =
{
name = "eclint";
description = "Find and fix problems according to .editorconfig.";
entry = "${settings.eclint.binPath} --fix";
};

rome =
{
name = "rome";
Expand Down
2 changes: 1 addition & 1 deletion nix/tools.nix
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ in
# TODO: these two should be statically compiled
inherit (haskellPackages) fourmolu;
inherit (luaPackages) luacheck;
inherit (nodePackages) eslint markdownlint-cli prettier cspell;
inherit (nodePackages) eslint markdownlint-cli prettier cspell eclint;
inherit (ocamlPackages) ocp-indent;
lua-language-server = lua-language-server;
purs-tidy = nodePackages.purs-tidy or null;
Expand Down

0 comments on commit 033453f

Please sign in to comment.