on master help sign in
Merge pull request #21 from obsidiansystems/aa-separate-haskell-overrides
239f5dbRyan Trinkle
default.nix+9−4
@@ -51,6 +51,13 @@ rec {
51 } ''
51 } ''
52 ln -s "$dir" "$out"
52 ln -s "$dir" "$out"
53 '';
53 '';
54+ haskellOverrides = self: super: {
55+ obelisk-asset-serve = self.callCabal2nix "obelisk-asset-serve" (hackGet ./asset + "/serve") {};
56+ obelisk-asset-manifest = self.callCabal2nix "obelisk-asset-manifest" (hackGet ./asset + "/manifest") {};
57+ obelisk-backend = self.callCabal2nix "obelisk-backend" ./backend {};
58+ obelisk-snap = self.callCabal2nix "obelisk-snap" ./snap {};
59+ obelisk-font-awesome = self.callCabal2nix "obelisk-font-awesome" (hackGet ./font-awesome) {};
60+ };
54 nullIfAbsent = p: if pathExists p then p else null;
61 nullIfAbsent = p: if pathExists p then p else null;
55 #TODO: Avoid copying files within the nix store. Right now, obelisk-asset-manifest-generate copies files into a big blob so that the android/ios static assets can be imported from there; instead, we should get everything lined up right before turning it into an APK, so that copies, if necessary, only exist temporarily.
62 #TODO: Avoid copying files within the nix store. Right now, obelisk-asset-manifest-generate copies files into a big blob so that the android/ios static assets can be imported from there; instead, we should get everything lined up right before turning it into an APK, so that copies, if necessary, only exist temporarily.
56 processAssets = { src, packageName ? "static", moduleName ? "Static" }: pkgs.runCommand "asset-manifest" {
63 processAssets = { src, packageName ? "static", moduleName ? "Static" }: pkgs.runCommand "asset-manifest" {
@@ -81,13 +88,11 @@ rec {
81 ${commonName} = nullIfAbsent (base + "/common");
88 ${commonName} = nullIfAbsent (base + "/common");
82 ${backendName} = nullIfAbsent (base + "/backend");
89 ${backendName} = nullIfAbsent (base + "/backend");
83 };
90 };
84− overrides = self: super: {
91+ projectOverrides = self: super: {
85 heist = doJailbreak super.heist; #TODO: Move up to reflex-platform; create tests for r-p supported packages
92 heist = doJailbreak super.heist; #TODO: Move up to reflex-platform; create tests for r-p supported packages
86 ${staticName} = dontHaddock (self.callCabal2nix "static" assets.haskellManifest {});
93 ${staticName} = dontHaddock (self.callCabal2nix "static" assets.haskellManifest {});
87− obelisk-asset-serve = self.callCabal2nix "obelisk-asset-serve" (hackGet ./asset + "/serve") {};
88− obelisk-asset-manifest = self.callCabal2nix "obelisk-asset-manifest" (hackGet ./asset + "/manifest") {};
89− obelisk-backend = self.callCabal2nix "obelisk-backend" ./backend {};
90 };
94 };
95+ overrides = composeExtensions haskellOverrides projectOverrides;
91 in {
96 in {
92 inherit packages overrides;
97 inherit packages overrides;
93 shells = {
98 shells = {