blob: 34829c14b7bb3d044071cf24961a10a13a546b51 (
plain) (
blame)
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
|
{ stdenv, buildGoModule, fetchFromGitHub, Security }:
buildGoModule rec {
pname = "ghq";
version = "1.1.0";
src = fetchFromGitHub {
owner = "x-motemen";
repo = "ghq";
rev = "v${version}";
sha256 = "1i0q9lxdxbyj0l0510cbkwkbycawrx8cxlbdrhb2p2fnk0vqnyiv";
};
modSha256 = "0hlbhky3c6zva9khn73n6xgq57k5p8anskxy3g2m0wzhr72cyc41";
buildInputs = stdenv.lib.optionals stdenv.isDarwin [ Security ];
buildFlagsArray = ''
-ldflags=
-X=main.Version=${version}
'';
postInstall = ''
install -m 444 -D ${src}/misc/zsh/_ghq $out/share/zsh/site-functions/_ghq
install -m 444 -D ${src}/misc/bash/_ghq $out/share/bash-completion/completions/_ghq
'';
meta = {
description = "Remote repository management made easy";
homepage = https://github.com/x-motemen/ghq;
maintainers = with stdenv.lib.maintainers; [ sigma ];
license = stdenv.lib.licenses.mit;
};
}
|