From ebe49463b89f83d2173cb890aecbbd6cc5d3a495 Mon Sep 17 00:00:00 2001 From: adisbladis Date: Wed, 25 Aug 2021 12:50:06 -0500 Subject: [PATCH] Add editorconfig-checker --- .gitignore | 3 +++ LICENSE.md | 4 +--- flake.nix | 19 +++++++++++++++++++ 3 files changed, 23 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 250b5c4..c6f9d8c 100644 --- a/.gitignore +++ b/.gitignore @@ -52,3 +52,6 @@ __pycache__/ .mypy_cache/ .dmypy.json dmypy.json + +# nix-direnv +.direnv diff --git a/LICENSE.md b/LICENSE.md index def709e..1110e89 100644 --- a/LICENSE.md +++ b/LICENSE.md @@ -1,7 +1,7 @@ GNU General Public License ========================== -_Version 3, 29 June 2007_ +_Version 3, 29 June 2007_ _Copyright © 2007 Free Software Foundation, Inc. <>_ Everyone is permitted to copy and distribute verbatim copies of this license @@ -593,5 +593,3 @@ more useful to permit linking proprietary applications with the library. If this what you want to do, use the GNU Lesser General Public License instead of this License. But first, please read <>. - - diff --git a/flake.nix b/flake.nix index 10b4427..a69e3d5 100644 --- a/flake.nix +++ b/flake.nix @@ -13,12 +13,31 @@ packages.nix-eval-jobs = pkgs.callPackage ./hydra.nix { srcDir = self; }; + + checks = { + + editorconfig = pkgs.runCommand "editorconfig-checks" { + nativeBuildInputs = [ + pkgs.editorconfig-checker + ]; + } '' + editorconfig-checker ${self} + touch $out + ''; + + }; + defaultPackage = self.packages.${system}.nix-eval-jobs; devShell = defaultPackage.overrideAttrs (old: { + nativeBuildInputs = old.nativeBuildInputs ++ [ + + pkgs.editorconfig-checker + (pkgs.python3.withPackages(ps: [ ps.pytest ])) + ]; }); });