From 51ceea404ee7a0d7f3bc1bad95fec836f0325c44 Mon Sep 17 00:00:00 2001 From: Patrick Sauter
Date: Sat, 22 May 2021 22:22:54 -0500 Subject: [PATCH] simplified --- .envrc | 1 - flake.lock | 6 +++--- flake.nix | 33 ++++++++++++--------------------- test.cabal => test2.cabal | 4 ++-- 4 files changed, 17 insertions(+), 27 deletions(-) delete mode 100644 .envrc rename test.cabal => test2.cabal (87%) diff --git a/.envrc b/.envrc deleted file mode 100644 index 3550a30..0000000 --- a/.envrc +++ /dev/null @@ -1 +0,0 @@ -use flake diff --git a/flake.lock b/flake.lock index 76d4a92..8c29795 100644 --- a/flake.lock +++ b/flake.lock @@ -23,11 +23,11 @@ "nixpkgs-unstable": "nixpkgs-unstable" }, "locked": { - "lastModified": 1621679414, - "narHash": "sha256-98HUjyuojrRl5SN4WNcSieDXCOHNXpBjrmcRVRhUJ3c=", + "lastModified": 1621732348, + "narHash": "sha256-o3Z1cCaioBKEIa5mdHEbWDWA4UXAPoJ1lQ4vHJ+WX0s=", "owner": "input-output-hk", "repo": "haskell.nix", - "rev": "6483dfaa928992d6f04a69ca785e60c46124a8d0", + "rev": "721740e01475d4765a3adeb6f70018acf937ac99", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index dc100f1..5ee36bc 100644 --- a/flake.nix +++ b/flake.nix @@ -6,28 +6,19 @@ inputs.flake-utils.url = "github:numtide/flake-utils"; outputs = { self, nixpkgs, haskellNix, flake-utils }: - flake-utils.lib.eachSystem [ "x86_64-linux" ] (system: + builtins.trace haskellNix (flake-utils.lib.eachSystem [ "x86_64-linux" ] (system: let - overlays = - [ haskellNix.overlay - (final: prev: { - test = final.haskell-nix.project { - src = ./.; - compiler-nix-name = "ghc8104"; - }; - }) - ]; - pkgs = import nixpkgs { inherit system overlays; }; - flake = pkgs.test.flake {}; + overlays = [ haskellNix.overlay (final: prev: { + test2 = final.haskell-nix.project' { + src = ./.; + compiler-nix-name = "ghc8104"; + }; + }) ]; + pkgs = import nixpkgs { inherit system overlays; }; + flake = pkgs.test2.flake {}; in flake // { - defaultPackage = flake.packages."test:exe:test"; - - devShell = pkgs.test.shellFor { - tools = { - cabal = "latest"; - }; - }; - } - ); + defaultPackage = flake.packages."test2:exe:test2"; + } + )); } diff --git a/test.cabal b/test2.cabal similarity index 87% rename from test.cabal rename to test2.cabal index fa8f660..de300fc 100644 --- a/test.cabal +++ b/test2.cabal @@ -1,11 +1,11 @@ cabal-version: >=1.10 -name: test +name: test2 version: 0.1.0.0 author: Test maintainer: test@test.test build-type: Simple -executable test +executable test2 main-is: Main.hs build-depends: base >=4.13 , reflex