stockholm/makefu/update-channel.sh
2018-08-29 00:24:34 +02:00

10 lines
388 B
Bash
Executable File

#!/bin/sh
dir=$(dirname $0)
oldref=$(cat $dir/nixpkgs.json | jq -r .rev | sed 's/\(.\{7\}\).*/\1/')
nix-shell -p nix-prefetch-git --run 'nix-prefetch-git \
--url https://github.com/makefu/nixpkgs \
--rev refs/heads/master' \
> $dir/nixpkgs.json
newref=$(cat $dir/nixpkgs.json | jq -r .rev | sed 's/\(.\{7\}\).*/\1/')
echo git commit $dir/nixpkgs.json -m "nixpkgs: $oldref -> $newref"