mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-27 08:04:14 +00:00
8603836e47
https://github.com/gohugoio/hugo/releases/tag/v0.96.0 As of 0.95.0 Hugo requires Go 1.18 to build. `gen autocomplete` is now deprecated in favor of `completion`: https://github.com/gohugoio/hugo/issues/8862
42 lines
985 B
Nix
42 lines
985 B
Nix
{ lib, buildGoModule, fetchFromGitHub, installShellFiles }:
|
|
|
|
buildGoModule rec {
|
|
pname = "hugo";
|
|
version = "0.96.0";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "gohugoio";
|
|
repo = pname;
|
|
rev = "v${version}";
|
|
sha256 = "sha256-3O+ZdOloh5gILPQssztt7s/MwRgDOnpJItwLn7FXnPU=";
|
|
};
|
|
|
|
vendorSha256 = "sha256-TgE/ToHBg2QBgtk0gPZTV/icIbQN14RpVAbL/8b+W0U=";
|
|
|
|
doCheck = false;
|
|
|
|
proxyVendor = true;
|
|
|
|
tags = [ "extended" ];
|
|
|
|
subPackages = [ "." ];
|
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
|
|
|
postInstall = ''
|
|
$out/bin/hugo gen man
|
|
installManPage man/*
|
|
installShellCompletion --cmd hugo \
|
|
--bash <($out/bin/hugo completion bash) \
|
|
--fish <($out/bin/hugo completion fish) \
|
|
--zsh <($out/bin/hugo completion 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 ];
|
|
};
|
|
}
|