···10 multi-ghc-travis = throw ("haskellPackages.multi-ghc-travis has been renamed"
11 + " to haskell-ci, which is now on hackage");
120013 # https://github.com/channable/vaultenv/issues/1
14 vaultenv = self.callPackage ../tools/haskell/vaultenv { };
15
···10 multi-ghc-travis = throw ("haskellPackages.multi-ghc-travis has been renamed"
11 + " to haskell-ci, which is now on hackage");
1213+ dconf2nix = self.callPackage ../tools/haskell/dconf2nix/dconf2nix.nix { };
14+15 # https://github.com/channable/vaultenv/issues/1
16 vaultenv = self.callPackage ../tools/haskell/vaultenv { };
17
···1+#!/usr/bin/env nix-shell
2+#!nix-shell -i bash -p cabal2nix curl jq
3+#
4+# This script will update the dconf2nix derivation to the latest version using
5+# cabal2nix.
6+7+set -eo pipefail
8+9+# This is the directory of this update.sh script.
10+script_dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
11+12+# dconf2nix derivation created with cabal2nix.
13+dconf2nix_derivation_file="${script_dir}/dconf2nix.nix"
14+15+# This is the current revision of dconf2nix in Nixpkgs.
16+old_version="$(sed -En 's/.*\bversion = "(.*?)".*/\1/p' "$dconf2nix_derivation_file")"
17+18+# This is the latest release version of dconf2nix on GitHub.
19+new_version=$(curl --silent "https://api.github.com/repos/gvolpe/dconf2nix/releases" | jq '.[0].tag_name' --raw-output)
20+21+echo "Updating dconf2nix from old version $old_version to new version $new_version."
22+echo "Running cabal2nix and outputting to ${dconf2nix_derivation_file}..."
23+24+cabal2nix --revision "$new_version" "https://github.com/gvolpe/dconf2nix.git" > "$dconf2nix_derivation_file"
25+26+echo "Finished."