Skip to content

Commit

Permalink
Update groundhog to throw SqlError instead of use fail
Browse files Browse the repository at this point in the history
  • Loading branch information
3noch committed May 7, 2020
1 parent ee08d02 commit 026ff08
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 11 deletions.
6 changes: 3 additions & 3 deletions default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@ let
aeson-gadt-th = repos.aeson-gadt-th;
bytestring-trie = repos.bytestring-trie;
dependent-monoidal-map = repos.dependent-monoidal-map;
groundhog = repos.groundhog + /groundhog;
groundhog-postgresql = repos.groundhog + /groundhog-postgresql;
groundhog-th = repos.groundhog + /groundhog-th;
groundhog = repos.groundhog + "/groundhog";
groundhog-postgresql = repos.groundhog + "/groundhog-postgresql";
groundhog-th = repos.groundhog + "/groundhog-th";
HaskellNet = repos.HaskellNet; # (super is marked as broken) unreleased fixes for newer GHC
HaskellNet-SSL = repos.HaskellNet-SSL; # (super is marked as broken)
postgresql-simple = repos.postgresql-simple; # v0.5.4.0 with a fix
Expand Down
7 changes: 1 addition & 6 deletions dep/groundhog/default.nix
Original file line number Diff line number Diff line change
@@ -1,7 +1,2 @@
# DO NOT HAND-EDIT THIS FILE
import ((import <nixpkgs> {}).fetchFromGitHub (
let json = builtins.fromJSON (builtins.readFile ./github.json);
in { inherit (json) owner repo rev sha256;
private = json.private or false;
}
))
import (import ./thunk.nix)
5 changes: 3 additions & 2 deletions dep/groundhog/github.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"owner": "obsidiansystems",
"repo": "groundhog",
"branch": "develop",
"rev": "e08021aef70f17196214e795789d0993177231b5",
"sha256": "13ikpayvzv85wmfgh7wnf73ayhjy77384mnwvqcxi0nbn5m7kk56"
"private": false,
"rev": "fb16055662e81bed258bd246380bc67bb6f7afab",
"sha256": "0071nvdw296bz5apvxg7r6inskg4znayqp050pjbnbl72b6aq8n8"
}
9 changes: 9 additions & 0 deletions dep/groundhog/thunk.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# DO NOT HAND-EDIT THIS FILE
let fetch = { private ? false, fetchSubmodules ? false, owner, repo, rev, sha256, ... }:
if !fetchSubmodules && !private then builtins.fetchTarball {
url = "https://github.com/${owner}/${repo}/archive/${rev}.tar.gz"; inherit sha256;
} else (import <nixpkgs> {}).fetchFromGitHub {
inherit owner repo rev sha256 fetchSubmodules private;
};
json = builtins.fromJSON (builtins.readFile ./github.json);
in fetch json

0 comments on commit 026ff08

Please sign in to comment.