37 lines
1.1 KiB
Nix
37 lines
1.1 KiB
Nix
{ stdenv, fetchFromGitHub, rustPlatform, cmake, pkgconfig, openssl, CoreServices }:
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
pname = "zola";
|
|
version = "0.9.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "getzola";
|
|
repo = pname;
|
|
rev = "v${version}";
|
|
sha256 = "0dbj2rkn4k5glnwdazsvjhah5pj9cbdb8hwlvm5q4njsmrgpyaw5";
|
|
};
|
|
|
|
cargoSha256 = "0i0xqbpbv3md42d2853cfzkhfwlkvxahhz5dldla5x96rm1i2hr8";
|
|
|
|
nativeBuildInputs = [ cmake pkgconfig ];
|
|
buildInputs = [ openssl ]
|
|
++ stdenv.lib.optional stdenv.isDarwin CoreServices;
|
|
|
|
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 ];
|
|
platforms = platforms.all;
|
|
};
|
|
}
|