-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Expand file tree
/
Copy pathdefault.nix
More file actions
49 lines (41 loc) · 1.28 KB
/
default.nix
File metadata and controls
49 lines (41 loc) · 1.28 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
{
lib,
self,
buildGoModule,
git,
icu,
...
}:
buildGoModule {
pname = "beads";
version = "1.0.0";
src = self;
# Point to the main Go package
subPackages = [ "cmd/bd" ];
doCheck = false;
# Go module dependencies hash - if build fails with hash mismatch, update with the "got:" value
vendorHash = "sha256-7eb7u47f4/OCnK/T56Zd6b5XUyV6vkBmissryBxANBU=";
# Relax go.mod version for Nix: nixpkgs Go may lag behind the latest
# patch release, and GOTOOLCHAIN=auto can't download in the Nix sandbox.
postPatch = ''
goVer="$(go env GOVERSION | sed 's/^go//')"
go mod edit -go="$goVer"
env
'';
# Allow patch-level toolchain upgrades when a dependency's minimum Go patch
# version is newer than nixpkgs' bundled patch version.
env.GOTOOLCHAIN = "auto";
# Due to https://github.com/dolthub/go-icu-regex, which requires
# separate install of icu headers and library.
env.CGO_CPPFLAGS="-I${icu.dev}/include";
env.CGO_LDFLAGS="-L${icu}/lib";
# Git is required for tests
nativeBuildInputs = [ git ];
meta = with lib; {
description = "beads (bd) - An issue tracker designed for AI-supervised coding workflows";
homepage = "https://github.com/gastownhall/beads";
license = licenses.mit;
mainProgram = "bd";
maintainers = [ ];
};
}