2020-09-25 04:45:31 +00:00
|
|
|
{ stdenv, fetchFromGitHub, rustPlatform, cmake, pkg-config, openssl, oniguruma, CoreServices }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "zola";
|
2020-10-07 09:15:18 +00:00
|
|
|
version = "0.12.1";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "getzola";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2020-10-07 09:15:18 +00:00
|
|
|
sha256 = "00fkcrr40v93z23h3q2wqlfx0120g59j6j9szk8nx9x85i40j3if";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2020-10-07 09:15:18 +00:00
|
|
|
cargoSha256 = "1wdypyy787dzdq5q64a9mjfygg0kli49yjzw7xh66sjd7263w9fs";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
nativeBuildInputs = [ cmake pkg-config ];
|
2020-09-25 04:45:31 +00:00
|
|
|
buildInputs = [ openssl oniguruma ]
|
2020-04-24 23:36:52 +00:00
|
|
|
++ stdenv.lib.optional stdenv.isDarwin CoreServices;
|
|
|
|
|
2020-09-25 04:45:31 +00:00
|
|
|
RUSTONIG_SYSTEM_LIBONIG = true;
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
postInstall = ''
|
|
|
|
install -D -m 444 completions/zola.bash \
|
|
|
|
-t $out/share/bash-completion/completions
|
|
|
|
install -D -m 444 completions/_zola \
|
|
|
|
-t $out/share/zsh/site-functions
|
|
|
|
install -D -m 444 completions/zola.fish \
|
|
|
|
-t $out/share/fish/vendor_completions.d
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "A fast static site generator with everything built-in";
|
|
|
|
homepage = "https://www.getzola.org/";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ dywedir ];
|
|
|
|
};
|
|
|
|
}
|