tvl-depot/blog/default.nix
William Carroll b25d06db7e Attempt to inject dependencies into blog/server
- We need the markdown files, to be in the /nix/store and the server needs to be
  aware of there location.
- Since we're dependending on `pandoc`, our server needs to know about it too.

For both of these cases -- especially for the latter case -- I imagine there may
be a more idiomatic way of doing this.
2020-01-23 21:57:25 +00:00

27 lines
571 B
Nix

{
pkgs ? import <nixpkgs> {},
depot ? import <depot> {},
universe ? import <universe> {},
...
}:
let
injectedPosts = pkgs.writeText "posts.lisp" ''
(in-package #:server)
(setq *path-to-posts* "${./posts}")
'';
injectedExecutables = pkgs.writeText "executables.lisp" ''
(in-package #:server)
(setq *pandoc-bin* "${pkgs.pandoc}/bin/pandoc")
'';
in depot.nix.buildLisp.program {
name = "server";
deps = with depot.third_party.lisp; [
hunchentoot
];
srcs = [
./src/server.lisp
injectedPosts
injectedExecutables
];
}