Add content hashes for pinned channels

This commit is contained in:
Erik Arvstedt 2019-11-07 21:57:00 +01:00
parent 961e8217a9
commit 46edb39d2f
No known key found for this signature in database
GPG Key ID: 33312B944DD97846
2 changed files with 20 additions and 3 deletions

6
helper/fetch-channel Executable file
View File

@ -0,0 +1,6 @@
#!/usr/bin/env bash
rev=$1
sha256=$(nix-prefetch-url --unpack https://github.com/nixos/nixpkgs-channels/archive/$rev.tar.gz)
echo "rev = \"$rev\";"
echo "sha256 = \"$sha256\";"

View File

@ -1,7 +1,18 @@
let
fetch = rev: builtins.fetchTarball "https://github.com/nixos/nixpkgs-channels/archive/${rev}.tar.gz";
fetch = { rev, sha256 }:
builtins.fetchTarball {
url = "https://github.com/nixos/nixpkgs-channels/archive/${rev}.tar.gz";
inherit sha256;
};
in
{
nixpkgs = fetch "27a5ddcf747fb2bb81ea9c63f63f2eb3eec7a2ec";
nixpkgs-unstable = fetch "4cd2cb43fb3a87f48c1e10bb65aee99d8f24cb9d";
# To update, run ../helper/fetch-channel REV
nixpkgs = fetch {
rev = "27a5ddcf747fb2bb81ea9c63f63f2eb3eec7a2ec";
sha256 = "1bp11q2marsqj3g2prdrghkhmv483ab5pi078d83xkhkk2jh3h81";
};
nixpkgs-unstable = fetch {
rev = "4cd2cb43fb3a87f48c1e10bb65aee99d8f24cb9d";
sha256 = "1d6rmq67kdg5gmk94wx2774qw89nvbhy6g1f2lms3c9ph37hways";
};
}