summaryrefslogtreecommitdiff
path: root/bragi/bar
diff options
context:
space:
mode:
authorGregor Kleen <gkleen@yggdrasil.li>2017-03-14 01:23:09 +0100
committerGregor Kleen <gkleen@yggdrasil.li>2017-03-14 01:23:09 +0100
commit47f54fc6d1f081c9fe7ac3d0bee705b3a78609d5 (patch)
treeac942d6b57a007a57906c1a8b13c63907c5f2ee7 /bragi/bar
parent3490d0dac52f79478fdb8db84106a505926e760f (diff)
downloadnixos-47f54fc6d1f081c9fe7ac3d0bee705b3a78609d5.tar
nixos-47f54fc6d1f081c9fe7ac3d0bee705b3a78609d5.tar.gz
nixos-47f54fc6d1f081c9fe7ac3d0bee705b3a78609d5.tar.bz2
nixos-47f54fc6d1f081c9fe7ac3d0bee705b3a78609d5.tar.xz
nixos-47f54fc6d1f081c9fe7ac3d0bee705b3a78609d5.zip
Switch to bar in repo
Diffstat (limited to 'bragi/bar')
-rw-r--r--bragi/bar/default.nix30
-rw-r--r--bragi/bar/generated.nix34
-rw-r--r--bragi/bar/generated.nix.gup5
3 files changed, 69 insertions, 0 deletions
diff --git a/bragi/bar/default.nix b/bragi/bar/default.nix
new file mode 100644
index 00000000..fd5e7acf
--- /dev/null
+++ b/bragi/bar/default.nix
@@ -0,0 +1,30 @@
1{ haskellPackages
2, stdenv
3, fetchFromGitHub
4, jquery
5}:
6
7let
8 pkg = haskellPackages.callPackage ./generated.nix {};
9 webshim = stdenv.mkDerivation rec {
10 name = "webshim-${version}";
11 version = "1.16.0";
12 src = fetchFromGitHub {
13 owner = "aFarkas";
14 repo = "webshim";
15 rev = "1.16.0";
16 sha256 = "14pk7hljqipzp0n7vpgcfxr3w4bla57cwyd7bmwmmxrm2zn62cyh";
17 };
18
19 installPhase = ''
20 mkdir -p $out/js
21 cp -r $src/js-webshim/dev/* $out/js/
22 '';
23 };
24in stdenv.lib.overrideDerivation pkg (drv: {
25 postUnpack = ''
26 rm -rf bar/static/jquery.js bar/static/webshim
27 ln -vs ${jquery}/js/jquery.js bar/static
28 ln -vs ${webshim}/js bar/static/webshim
29 '';
30})
diff --git a/bragi/bar/generated.nix b/bragi/bar/generated.nix
new file mode 100644
index 00000000..4243ad4d
--- /dev/null
+++ b/bragi/bar/generated.nix
@@ -0,0 +1,34 @@
1{ mkDerivation, aeson, base, bytestring, case-insensitive
2, classy-prelude, classy-prelude-conduit, classy-prelude-yesod
3, conduit, containers, data-default, directory, fast-logger
4, fetchgit, file-embed, hjsmin, http-conduit, lens, monad-control
5, monad-logger, mtl, persistent, persistent-postgresql
6, persistent-template, safe, shakespeare, stdenv, template-haskell
7, text, time, unordered-containers, vector, wai, wai-extra
8, wai-logger, warp, yaml, yesod, yesod-auth, yesod-core, yesod-form
9, yesod-static
10}:
11mkDerivation {
12 pname = "bar";
13 version = "0.0.0";
14 src = fetchgit {
15 url = "git://git.yggdrasil.li/gkleen/pub/bar";
16 sha256 = "13h5hxwx4y79jr19l894zq4ynvkmhfds52xm8dlsdl5j69gg7laa";
17 rev = "53fcf55c02f9335518c28d26429913258fc28f87";
18 };
19 isLibrary = true;
20 isExecutable = true;
21 libraryHaskellDepends = [
22 aeson base bytestring case-insensitive classy-prelude
23 classy-prelude-conduit classy-prelude-yesod conduit containers
24 data-default directory fast-logger file-embed hjsmin http-conduit
25 lens monad-control monad-logger mtl persistent
26 persistent-postgresql persistent-template safe shakespeare
27 template-haskell text time unordered-containers vector wai
28 wai-extra wai-logger warp yaml yesod yesod-auth yesod-core
29 yesod-form yesod-static
30 ];
31 executableHaskellDepends = [ base ];
32 doHaddock = false;
33 license = stdenv.lib.licenses.unfree;
34}
diff --git a/bragi/bar/generated.nix.gup b/bragi/bar/generated.nix.gup
new file mode 100644
index 00000000..eeb13ad2
--- /dev/null
+++ b/bragi/bar/generated.nix.gup
@@ -0,0 +1,5 @@
1#!/usr/bin/env zsh
2
3gup -u ${2:r}.cabal
4cd ${2:h}
5cabal2nix --no-haddock "git://git.yggdrasil.li/gkleen/pub/bar" >! ${1}