git.iko.soy/nixpkgs-stackage
on master help sign in
Automate update script
commit6d4ace261ebfd08a96381d999dbd6a4b6e3d043a authorDmitry Bushev <bushevdv@gmail.com> dateSat 30 Dec 2017, 23:19 (9 years ago) parent6e22272
4 files changed+20−3
cacheVersion.txt+1 haskell-overlay.nix+4−1 stackage2nix/default.nix+3−2 update.sh+12
cacheVersion.txtnew file+1
@@ -0,0 +1 @@
1+2017-12-30
haskell-overlay.nix+4−1
@@ -7,5 +7,8 @@ self: super:
77 };
88 };
99
10− stackage2nix = import ./stackage2nix { nixpkgs = self; };
10+ stackage2nix = import ./stackage2nix {
11+ nixpkgs = self;
12+ cacheVersion = builtins.readFile ./cacheVersion.txt;
13+ };
1114}
stackage2nix/default.nix+3−2
@@ -1,8 +1,9 @@
1−{ nixpkgs ? import ../default.nix {} }:
1+{ nixpkgs ? import ../default.nix {}
2+, cacheVersion }:
23
34with nixpkgs;
45let
5− lib = callPackage ./lib.nix {};
6+ lib = callPackage ./lib.nix { inherit cacheVersion; };
67 haskellPackages = haskell.packages.stackage.lts-100;
78 stackage2nix = haskell.lib.disableSharedExecutables
89 (haskellPackages.callPackage ./stackage2nix.nix {});
update.shnew file+12
@@ -0,0 +1,12 @@
1+#!/bin/sh
2+#
3+# nixpkgs-typeable update script
4+#
5+# - updates ./cacheVersion.txt, this will trigger updates of
6+# `stackage-lts`, `all-cabal-hashes` and `hackage-db`
7+# - generates new stackage releases in `stackage` directory
8+# - updates `stackage/default.nix` index
9+
10+DATE=$(date --iso-8601)
11+echo $DATE > cacheVersion.txt
12+exec nix-shell update.nix --argstr cacheVersion "$DATE"