diff --git a/flake.lock b/flake.lock index c862594..4475846 100644 --- a/flake.lock +++ b/flake.lock @@ -15,21 +15,6 @@ "type": "github" } }, - "flake-utils_2": { - "locked": { - "lastModified": 1667077288, - "narHash": "sha256-bdC8sFNDpT0HK74u9fUkpbf1MEzVYJ+ka7NXCdgBoaA=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "6ee9ebb6b1ee695d2cacc4faa053a7b9baa76817", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { "lastModified": 1668908668, @@ -46,44 +31,10 @@ "type": "github" } }, - "nixpkgs_2": { - "locked": { - "lastModified": 1667292599, - "narHash": "sha256-7ISOUI1aj6UKMPIL+wwthENL22L3+A9V+jS8Is3QsRo=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "ef2f213d9659a274985778bff4ca322f3ef3ac68", - "type": "github" - }, - "original": { - "id": "nixpkgs", - "type": "indirect" - } - }, - "pre-commit-hooks": { - "inputs": { - "flake-utils": "flake-utils_2", - "nixpkgs": "nixpkgs_2" - }, - "locked": { - "lastModified": 1668960094, - "narHash": "sha256-RwSw+hh4Vacceh57gSaquzUoDmBu+ey6rjR+mZ8vsIg=", - "owner": "cachix", - "repo": "pre-commit-hooks.nix", - "rev": "0c9555d4e0943fec80a9087b8d3855a49533f399", - "type": "github" - }, - "original": { - "owner": "cachix", - "repo": "pre-commit-hooks.nix", - "type": "github" - } - }, "root": { "inputs": { "flake-utils": "flake-utils", - "nixpkgs": "nixpkgs", - "pre-commit-hooks": "pre-commit-hooks" + "nixpkgs": "nixpkgs" } } }, diff --git a/flake.nix b/flake.nix index 1a60462..8da9607 100644 --- a/flake.nix +++ b/flake.nix @@ -9,11 +9,9 @@ url = github:numtide/flake-utils; inputs.nixpkgs.follows = "nixpkgs"; }; - - pre-commit-hooks.url = "github:cachix/pre-commit-hooks.nix"; }; - outputs = { self, nixpkgs, flake-utils, pre-commit-hooks }: + outputs = { self, nixpkgs, flake-utils }: let ghcVersion = "924"; compiler = "ghc${ghcVersion}"; @@ -53,7 +51,6 @@ # Note: cannot reference anything that depends on `evalPkgs` like `hsPkgs` # otherwise non-x86_64-linux users will not be able to build the dev env devShell = pkgs.mkShell { - inherit (self.checks.${system}.pre-commit-check) shellHook; buildInputs = with pkgs; [ cabal2nix cabal-install @@ -73,23 +70,6 @@ cofree-bot = hsPkgs.cofree-bot; }; - checks = { - pre-commit-check = pre-commit-hooks.lib.${system}.run { - src = ./.; - hooks = { - nixpkgs-fmt.enable = true; - ormolu = { - name = "ormolu"; - entry = "${pkgs.ormolu}/bin/ormolu --mode inplace $(git ls-files '*.hs')"; - files = "\\.l?hs$"; - language = "system"; - pass_filenames = false; - }; - cabal-fmt.enable = true; - }; - }; - }; - defaultPackage = packages.cofree-bot; }); }