diff options
author | Eric Sagnes <eric.sagnes@gmail.com> | 2016-10-07 14:08:24 +0900 |
---|---|---|
committer | Eric Sagnes <eric.sagnes@gmail.com> | 2016-10-07 15:25:20 +0900 |
commit | 3cc8f2108609706c35a5175b5e32db82000aeea9 (patch) | |
tree | 62eb2d669ba58fb9874da231cbc578f97880d776 /pkgs/applications/misc/styx | |
parent | cb1d47569393cfd2b78eebc12ae07fd8f0291a5d (diff) | |
download | nixlib-3cc8f2108609706c35a5175b5e32db82000aeea9.tar nixlib-3cc8f2108609706c35a5175b5e32db82000aeea9.tar.gz nixlib-3cc8f2108609706c35a5175b5e32db82000aeea9.tar.bz2 nixlib-3cc8f2108609706c35a5175b5e32db82000aeea9.tar.lz nixlib-3cc8f2108609706c35a5175b5e32db82000aeea9.tar.xz nixlib-3cc8f2108609706c35a5175b5e32db82000aeea9.tar.zst nixlib-3cc8f2108609706c35a5175b5e32db82000aeea9.zip |
styx: init at 0.1.0
Diffstat (limited to 'pkgs/applications/misc/styx')
-rw-r--r-- | pkgs/applications/misc/styx/default.nix | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/pkgs/applications/misc/styx/default.nix b/pkgs/applications/misc/styx/default.nix new file mode 100644 index 000000000000..e44efc0f16d8 --- /dev/null +++ b/pkgs/applications/misc/styx/default.nix @@ -0,0 +1,43 @@ +{ stdenv, fetchFromGitHub, caddy, asciidoctor }: + +stdenv.mkDerivation rec { + name = "styx-${version}"; + version = "0.1.0"; + + src = fetchFromGitHub { + owner = "styx-static"; + repo = "styx"; + rev = "v${version}"; + sha256 = "0lz6mfawschfjg4mvfsqz9dv884x2lcg787zjdlnhdi5yqmjx29r"; + }; + + server = caddy.bin; + + nativeBuildInputs = [ asciidoctor ]; + + setSourceRoot = "cd styx-*/src; export sourceRoot=`pwd`"; + + installPhase = '' + mkdir $out + install -D -m 777 $sourceRoot/styx.sh $out/bin/styx + + mkdir -p $out/share/styx + cp -r $sourceRoot/sample $out/share/styx + + mkdir -p $out/share/doc/styx + asciidoctor $sourceRoot/doc/manual.doc -o $out/share/doc/styx/index.html + + substituteAllInPlace $out/bin/styx + substituteAllInPlace $out/share/styx/sample/templates/feed.nix + substituteAllInPlace $out/share/doc/styx/index.html + ''; + + meta = with stdenv.lib; { + description = "Nix based static site generator"; + maintainers = with maintainers; [ ericsagnes ]; + homepage = https://styx-static.github.io/styx-site/; + downloadPage = https://github.com/styx-static/styx/; + platforms = platforms.all; + license = licenses.mit; + }; +} |