diff options
author | Gregor Kleen <gkleen@yggdrasil.li> | 2022-02-27 14:38:05 +0100 |
---|---|---|
committer | Gregor Kleen <gkleen@yggdrasil.li> | 2022-02-27 14:38:05 +0100 |
commit | 2a3c28331899cd76e5afc223e1a0ebf85a422c44 (patch) | |
tree | dac5e9ed018c2123eac7b9818ca686036c3df0b7 /overlays/fast-cli.nix | |
parent | 9c03c3a5b97d9712aaab2823daea63580f60b975 (diff) | |
download | nixos-2a3c28331899cd76e5afc223e1a0ebf85a422c44.tar nixos-2a3c28331899cd76e5afc223e1a0ebf85a422c44.tar.gz nixos-2a3c28331899cd76e5afc223e1a0ebf85a422c44.tar.bz2 nixos-2a3c28331899cd76e5afc223e1a0ebf85a422c44.tar.xz nixos-2a3c28331899cd76e5afc223e1a0ebf85a422c44.zip |
fast-cli: go version
Diffstat (limited to 'overlays/fast-cli.nix')
-rw-r--r-- | overlays/fast-cli.nix | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/overlays/fast-cli.nix b/overlays/fast-cli.nix new file mode 100644 index 00000000..314d3796 --- /dev/null +++ b/overlays/fast-cli.nix | |||
@@ -0,0 +1,40 @@ | |||
1 | final: prev: { | ||
2 | fast-cli = prev.buildGoModule rec { | ||
3 | pname = "fast-cli"; | ||
4 | version = "0.2.10"; | ||
5 | |||
6 | src = prev.fetchFromGitHub { | ||
7 | owner = "gesquive"; | ||
8 | repo = pname; | ||
9 | rev = "v${version}"; | ||
10 | hash = "sha256-j7/3Llc3jTeJGpOH3Aexm9qcNscuk0mbi4ZCCyzC3+s="; | ||
11 | }; | ||
12 | vendorSha256 = "sha256-XM/5kUau0JBMxN0UpX6QNI31i8/+HNFvgFUFtlJsBh0="; | ||
13 | |||
14 | preBuild = let | ||
15 | goMod = prev.writeText "go.mod" '' | ||
16 | module github.com/gesquive/fast-cli | ||
17 | |||
18 | go 1.17 | ||
19 | |||
20 | require ( | ||
21 | github.com/dustin/go-humanize v0.0.0-20170228161531-259d2a102b87 | ||
22 | github.com/fatih/color v1.4.1 | ||
23 | github.com/gesquive/cli v0.2.0 | ||
24 | github.com/inconshreveable/mousetrap v1.0.0 | ||
25 | github.com/mattn/go-colorable v0.0.8-0.20170210172801-5411d3eea597 | ||
26 | github.com/mattn/go-isatty v0.0.2-0.20170307163044-57fdcb988a5c | ||
27 | github.com/spf13/cobra v0.0.0-20170531045452-8d4ce3549a0b | ||
28 | github.com/spf13/pflag v1.0.0 | ||
29 | golang.org/x/sys v0.0.0-20170213225739-e24f485414ae | ||
30 | ) | ||
31 | ''; | ||
32 | in '' | ||
33 | install -v -m 0644 ${goMod} ./go.mod | ||
34 | ''; | ||
35 | |||
36 | ldflags = [ | ||
37 | "-X main.version=${version}" | ||
38 | ]; | ||
39 | }; | ||
40 | } | ||