Add default.nix

This commit is contained in:
Tim Schubert 2020-10-23 19:41:36 +02:00
parent b89a04df8d
commit f0f8ba4118
Signed by: dadada
GPG key ID: EEB8D1CE62C4DFEA
7 changed files with 15 additions and 0 deletions

1
.gitignore vendored
View file

@ -1 +1,2 @@
*.html *.html
result

14
default.nix Normal file
View file

@ -0,0 +1,14 @@
{ pkgs ? import <nixpkgs> {} }:
pkgs.stdenv.mkDerivation rec {
src = ./src;
nativeBuildInputs = [ pkgs.pandoc ];
buildPhase = ''
find . -iname "*.md" -type f -exec sh -c 'pandoc -s -f commonmark -t html --template template.html -o "''${0%.md}.html" "''${0}"' {} \;
'';
installPhase = ''
mkdir -p $out
cp -r . $out/
'';
name = "dadada.li";
version = "0.1";
}

View file

Before

Width:  |  Height:  |  Size: 19 KiB

After

Width:  |  Height:  |  Size: 19 KiB

Before After
Before After