mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-11-06 18:26:45 +01:00
42 lines
1 KiB
Nix
42 lines
1 KiB
Nix
{ lib, buildGoModule, fetchFromGitHub, installShellFiles }:
|
|
|
|
buildGoModule rec {
|
|
pname = "hugo";
|
|
version = "0.82.1";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "gohugoio";
|
|
repo = pname;
|
|
rev = "v${version}";
|
|
sha256 = "sha256-6poWFcApwCos3XvS/Wq1VJyf5xTUWtqWNFXIhjNsXVs=";
|
|
};
|
|
|
|
vendorSha256 = "sha256-pJBm+yyy1DbH28oVBQA+PHSDtSg3RcgbRlurrwnnEls=";
|
|
|
|
doCheck = false;
|
|
|
|
runVend = true;
|
|
|
|
buildFlags = [ "-tags" "extended" ];
|
|
|
|
subPackages = [ "." ];
|
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
|
|
|
postInstall = ''
|
|
$out/bin/hugo gen man
|
|
installManPage man/*
|
|
installShellCompletion --cmd hugo \
|
|
--bash <($out/bin/hugo gen autocomplete --type=bash) \
|
|
--fish <($out/bin/hugo gen autocomplete --type=fish) \
|
|
--zsh <($out/bin/hugo gen autocomplete --type=zsh)
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "A fast and modern static website engine";
|
|
homepage = "https://gohugo.io";
|
|
license = licenses.asl20;
|
|
maintainers = with maintainers; [ schneefux Br1ght0ne Frostman ];
|
|
};
|
|
}
|