2020-02-18 07:22:38 +01:00
|
|
|
{ stdenv, fetchFromGitHub, rustPlatform, cmake, pkg-config, openssl, CoreServices }:
|
2017-12-29 07:13:47 +01:00
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
2019-03-25 22:26:07 +01:00
|
|
|
pname = "zola";
|
2020-03-13 02:20:20 +01:00
|
|
|
version = "0.10.1";
|
2017-12-29 07:13:47 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2018-11-17 23:53:15 +01:00
|
|
|
owner = "getzola";
|
2019-03-25 22:26:07 +01:00
|
|
|
repo = pname;
|
2017-12-29 07:13:47 +01:00
|
|
|
rev = "v${version}";
|
2020-03-13 02:20:20 +01:00
|
|
|
sha256 = "07zg4ia983rgvgvmw4xbi347lr4rxlf1xv8rw72cflc74kyia67n";
|
2017-12-29 07:13:47 +01:00
|
|
|
};
|
|
|
|
|
2020-03-13 02:20:20 +01:00
|
|
|
cargoSha256 = "13lnl01h8k8xv2ls1kjskfnyjmmk8iyk2mvbk01p2wmhp5m876md";
|
2020-02-14 03:00:26 +01:00
|
|
|
|
2020-02-18 07:22:38 +01:00
|
|
|
nativeBuildInputs = [ cmake pkg-config ];
|
2019-06-19 23:19:13 +02:00
|
|
|
buildInputs = [ openssl ]
|
|
|
|
++ stdenv.lib.optional stdenv.isDarwin CoreServices;
|
2017-12-29 07:13:47 +01:00
|
|
|
|
|
|
|
postInstall = ''
|
2018-11-17 23:53:15 +01:00
|
|
|
install -D -m 444 completions/zola.bash \
|
2017-12-29 07:13:47 +01:00
|
|
|
-t $out/share/bash-completion/completions
|
2018-11-17 23:53:15 +01:00
|
|
|
install -D -m 444 completions/_zola \
|
2017-12-29 07:13:47 +01:00
|
|
|
-t $out/share/zsh/site-functions
|
2018-11-17 23:53:15 +01:00
|
|
|
install -D -m 444 completions/zola.fish \
|
2017-12-29 07:13:47 +01:00
|
|
|
-t $out/share/fish/vendor_completions.d
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
2018-11-17 23:53:15 +01:00
|
|
|
description = "A fast static site generator with everything built-in";
|
2020-02-18 07:22:38 +01:00
|
|
|
homepage = "https://www.getzola.org/";
|
2017-12-29 07:13:47 +01:00
|
|
|
license = licenses.mit;
|
2018-07-14 20:32:15 +02:00
|
|
|
maintainers = with maintainers; [ dywedir ];
|
2017-12-29 07:13:47 +01:00
|
|
|
platforms = platforms.all;
|
|
|
|
};
|
|
|
|
}
|