15 src = fetchFromGitHub {
18 rev = "refs/tags/v${version}";
19 hash = "sha256-96ikGGKw9IN/ch199oFcucp8aVR+fEiAWBeu39J2Osw=";
22 vendorHash = "sha256-kUKnoUQzLbi0ssxvK2viNTHLtqx8vaHLYXO8ZWU2rmw=";
28 tags = [ "extended" ];
30 subPackages = [ "." ];
32 nativeBuildInputs = [ installShellFiles ];
34 ldflags = [ "-s" "-w" "-X github.com/gohugoio/hugo/common/hugo.vendorInfo=nixpkgs" ];
36 postInstall = let emulator = stdenv.hostPlatform.emulator buildPackages; in ''
37 ${emulator} $out/bin/hugo gen man
39 installShellCompletion --cmd hugo \
40 --bash <(${emulator} $out/bin/hugo completion bash) \
41 --fish <(${emulator} $out/bin/hugo completion fish) \
42 --zsh <(${emulator} $out/bin/hugo completion zsh)
45 passthru.tests.version = testers.testVersion {
47 command = "hugo version";
48 version = "v${version}";
52 description = "A fast and modern static website engine";
53 homepage = "https://gohugo.io";
54 license = licenses.asl20;
55 maintainers = with maintainers; [ schneefux Br1ght0ne Frostman ];