Add nix derivation
This commit is contained in:
parent
747518600c
commit
66ad565cba
1
.gitignore
vendored
1
.gitignore
vendored
@ -1,3 +1,4 @@
|
|||||||
.stack-work/
|
.stack-work/
|
||||||
.vscode/
|
.vscode/
|
||||||
*.swp
|
*.swp
|
||||||
|
result
|
||||||
|
@ -32,7 +32,7 @@ library:
|
|||||||
source-dirs: src
|
source-dirs: src
|
||||||
|
|
||||||
executables:
|
executables:
|
||||||
utoy-exe:
|
utoy:
|
||||||
main: Main.hs
|
main: Main.hs
|
||||||
source-dirs: app
|
source-dirs: app
|
||||||
ghc-options:
|
ghc-options:
|
||||||
|
@ -36,7 +36,7 @@ library
|
|||||||
, text
|
, text
|
||||||
default-language: Haskell2010
|
default-language: Haskell2010
|
||||||
|
|
||||||
executable utoy-exe
|
executable utoy
|
||||||
main-is: Main.hs
|
main-is: Main.hs
|
||||||
hs-source-dirs:
|
hs-source-dirs:
|
||||||
app
|
app
|
||||||
|
20
utoy.nix
Normal file
20
utoy.nix
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
let
|
||||||
|
pkgs = import ./nix/pkgs.nix {};
|
||||||
|
settings = import ./nix/settings.nix;
|
||||||
|
haskellDeps = import ./nix/haskell-deps.nix;
|
||||||
|
|
||||||
|
haskellPackages = pkgs.haskell.packages."${settings.ghc}";
|
||||||
|
|
||||||
|
utoy =
|
||||||
|
{ mkDerivation }:
|
||||||
|
mkDerivation {
|
||||||
|
version = "0.1.0.0";
|
||||||
|
pname = "utoy";
|
||||||
|
license = pkgs.lib.licenses.mit;
|
||||||
|
src = ./.;
|
||||||
|
|
||||||
|
libraryHaskellDepends = haskellDeps haskellPackages;
|
||||||
|
};
|
||||||
|
in
|
||||||
|
pkgs.haskell.lib.justStaticExecutables
|
||||||
|
(haskellPackages.callPackage utoy {})
|
Loading…
x
Reference in New Issue
Block a user