Upgrade nixpkgs to current master and add an upgrade checklist (#1579)

* simplify haskell packages overrides based on new nixpkgs
* update Nix gitignore
* simplify Haskell packages overlay

Co-authored-by: monacoremo <monacoremo>
This commit is contained in:
Remo Rechkemmer
2020-09-09 19:08:16 -05:00
committed by GitHub
co-authored by monacoremo <monacoremo>
parent bd2160db26
commit 7af54c5813
12 changed files with 188 additions and 90 deletions
+1 -1
View File
@@ -1,7 +1,7 @@
{
gitignore = import ./gitignore.nix;
ghr = import ./ghr;
haskell-packages = import ./haskell-packages;
haskell-packages = import ./haskell-packages.nix;
postgresql-default = import ./postgresql-default.nix;
postgresql-legacy = import ./postgresql-legacy.nix;
}
+3
View File
@@ -12,4 +12,7 @@ buildGoModule rec {
};
vendorSha256 = "14avsngzhl1b8a05i43ph6sxh9vj0jls0acxr9j7r0h3f0vpamcj";
# Disabling tests, as they require a GitHub API token
doCheck = false;
}
+2 -2
View File
@@ -12,8 +12,8 @@ self: super:
gitignoreSrc = super.fetchFromGitHub {
owner = "hercules-ci";
repo = "gitignore";
rev = "2ced4519f865341adcb143c5d668f955a2cb997f";
sha256 = "sha256:0fc5bgv9syfcblp23y05kkfnpgh3gssz6vn24frs8dzw39algk2z";
rev = "c4662e662462e7bf3c2a968483478a665d00e717";
sha256 = "1npnx0h6bd0d7ql93ka7azhj40zgjp815fw2r6smg8ch9p7mzdlx";
};
in
(super.callPackage gitignoreSrc { }).gitignoreSource;
+31
View File
@@ -0,0 +1,31 @@
{ compiler, extraOverrides ? (final: prev: { }) }:
self: super:
let
overrides =
final: prev:
rec {
# To pin custom versions of Haskell packages:
# protolude =
# prev.callHackageDirect
# {
# pkg = "protolude";
# ver = "0.3.0";
# sha256 = "0iwh4wsjhb7pms88lw1afhdal9f86nrrkkvv65f9wxbd1b159n72";
# }
# { };
#
# To get the sha256:
# nix-prefetch-url --unpack https://hackage.haskell.org/package/protolude-0.3.0/protolude-0.3.0.tar.gz
protolude = prev.protolude_0_3_0;
} // extraOverrides final prev;
in
{
haskell =
super.haskell // {
packages = super.haskell.packages // {
"${compiler}" =
super.haskell.packages."${compiler}".override { inherit overrides; };
};
};
}
-10
View File
@@ -1,10 +0,0 @@
The `.nix` files in this directory pin specific versions of Haskell packages
from Hackage. They were generated with `cabal2nix`, e.g.:
```bash
cabal2nix cabal://Cabal-3.0.0.0 > Cabal.nix
```
Those overrides will likely become obsolete as the pinned versions are adopted
into our pinned version of nixpkgs.
-38
View File
@@ -1,38 +0,0 @@
{ compiler, extraOverrides ? (final: prev: { }) }:
self: super:
let
overrides =
final: prev:
rec {
protolude =
prev.callHackageDirect
{
pkg = "protolude";
ver = "0.3.0";
sha256 = "0iwh4wsjhb7pms88lw1afhdal9f86nrrkkvv65f9wxbd1b159n72";
} { };
# To get the sha256
# nix-prefetch-url --unpack https://hackage.haskell.org/package/hasql-notifications-0.1.0.0/hasql-notifications-0.1.0.0.tar.gz
hasql-notifications =
self.haskell.lib.overrideCabal
(
prev.callHackageDirect
{
pkg = "hasql-notifications";
ver = "0.1.0.0";
sha256 = "1z17gsqvvzzi0yipc3qy3jz8vzpww4vsc4vaj2kbzr2mfliq6fx3";
} { }
)
(old: { doCheck = false; });
} // extraOverrides final prev;
in
{
haskell =
super.haskell // {
packages = super.haskell.packages // {
"${compiler}" =
super.haskell.packages."${compiler}".override { inherit overrides; };
};
};
}