3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/applications/version-management/git-and-tools/ghq/default.nix

34 lines
819 B
Nix
Raw Normal View History

{ lib, buildGoModule, fetchFromGitHub }:
2017-04-15 03:57:38 +01:00
buildGoModule rec {
pname = "ghq";
2021-08-08 13:09:59 +01:00
version = "1.2.1";
2017-04-15 03:57:38 +01:00
src = fetchFromGitHub {
2020-02-23 11:19:24 +00:00
owner = "x-motemen";
2017-04-15 03:57:38 +01:00
repo = "ghq";
rev = "v${version}";
2021-08-08 13:09:59 +01:00
sha256 = "sha256-86ZFKkzDAhx3UYWxreQI2OJJmqGnqaH2TgwQunuYhv4=";
2017-04-15 03:57:38 +01:00
};
2021-02-25 10:07:02 +00:00
vendorSha256 = "sha256-5Eth9v98z1gxf1Fz5Lbn2roX7dSBmA7GRzg8uvT0hTI=";
2017-04-15 03:57:38 +01:00
doCheck = false;
2021-08-26 07:45:51 +01:00
ldflags = [
"-X=main.Version=${version}"
];
2017-04-15 03:57:38 +01:00
postInstall = ''
2020-02-23 11:19:24 +00:00
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
2017-04-15 03:57:38 +01:00
'';
meta = {
description = "Remote repository management made easy";
homepage = "https://github.com/x-motemen/ghq";
2021-01-15 13:21:58 +00:00
maintainers = with lib.maintainers; [ sigma ];
license = lib.licenses.mit;
2017-04-15 03:57:38 +01:00
};
}