lol
1{
2 lib,
3 stdenv,
4 fetchFromGitHub,
5 rustPlatform,
6 versionCheckHook,
7 nix-update-script,
8}:
9
10rustPlatform.buildRustPackage (finalAttrs: {
11 pname = "cobalt";
12 version = "0.20.1";
13
14 src = fetchFromGitHub {
15 owner = "cobalt-org";
16 repo = "cobalt.rs";
17 tag = "v${finalAttrs.version}";
18 hash = "sha256-0MwIJJ7oNUFMNqMzew9HgaZsfBNczBli20vsxtIWZq0=";
19 };
20
21 cargoHash = "sha256-4oLEInL5hocCkP20lrOzfwPm5ram8Xw6p1qSva1tzNQ=";
22
23 nativeInstallCheckInputs = [ versionCheckHook ];
24 versionCheckProgramArg = "--version";
25 doInstallCheck = true;
26
27 passthru.updateScript = nix-update-script { };
28
29 meta = {
30 description = "Static site generator written in Rust";
31 homepage = "https://cobalt-org.github.io/";
32 downloadPage = "https://github.com/cobalt-org/cobalt.rs/";
33 changelog = "https://github.com/cobalt-org/cobalt.rs/releases/tag/v${finalAttrs.version}";
34 license = lib.licenses.mit;
35 maintainers = with lib.maintainers; [ ethancedwards8 ];
36 platforms = lib.platforms.unix;
37 mainProgram = "cobalt";
38 };
39})