Skip to content

Commit 8a97acd

Browse files
authored
go-graft, gg: merge duplicated package (#387824)
2 parents 44e1bd5 + 2270999 commit 8a97acd

File tree

3 files changed

+29
-49
lines changed

3 files changed

+29
-49
lines changed

pkgs/by-name/gg/gg/package.nix

Lines changed: 0 additions & 43 deletions
This file was deleted.

pkgs/by-name/go/go-graft/package.nix

Lines changed: 28 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,9 @@
1-
{ lib, fetchFromGitHub, buildGoModule }:
1+
{
2+
lib,
3+
fetchFromGitHub,
4+
buildGoModule,
5+
installShellFiles,
6+
}:
27

38
buildGoModule rec {
49
pname = "go-graft";
@@ -8,20 +13,37 @@ buildGoModule rec {
813
owner = "mzz2017";
914
repo = "gg";
1015
rev = "v${version}";
11-
sha256 = "sha256-DXW0NtFYvcCX4CgMs5/5HPaO9f9eFtw401wmJdCbHPU=";
16+
hash = "sha256-DXW0NtFYvcCX4CgMs5/5HPaO9f9eFtw401wmJdCbHPU=";
1217
};
1318

1419
env.CGO_ENABLED = 0;
1520

16-
ldflags = [ "-X github.com/mzz2017/gg/cmd.Version=${version}" "-s" "-w" ];
21+
ldflags = [
22+
"-X github.com/mzz2017/gg/cmd.Version=${version}"
23+
"-s"
24+
"-w"
25+
];
26+
1727
vendorHash = "sha256-fnM4ycqDyruCdCA1Cr4Ki48xeQiTG4l5dLVuAafEm14=";
18-
subPackages = [ "." ];
28+
29+
nativeBuildInputs = [ installShellFiles ];
30+
31+
postInstall = ''
32+
installShellCompletion --cmd gg \
33+
--bash completion/bash/gg \
34+
--fish completion/fish/gg.fish \
35+
--zsh completion/zsh/_gg
36+
'';
1937

2038
meta = with lib; {
2139
description = "Command-line tool for one-click proxy in your research and development without installing v2ray or anything else";
40+
changelog = "https://github.com/mzz2017/gg/releases/tag/${src.rev}";
2241
homepage = "https://github.com/mzz2017/gg";
23-
license = licenses.agpl3Plus;
24-
maintainers = with maintainers; [ xyenon ];
42+
license = licenses.agpl3Only;
43+
maintainers = with maintainers; [
44+
xyenon
45+
oluceps
46+
];
2547
mainProgram = "gg";
2648
platforms = platforms.linux;
2749
};

pkgs/top-level/aliases.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -529,6 +529,7 @@ mapAliases {
529529
gfortran49 = throw "'gfortran49' has been removed from nixpkgs"; # Added 2024-09-11
530530
gfortran7 = throw "gfortran7 has been removed from Nixpkgs, as it is unmaintained and obsolete"; # Added 2024-11-20
531531
gfortran8 = throw "gfortran8 has been removed from Nixpkgs, as it is unmaintained and obsolete"; # Added 2024-11-20
532+
gg = go-graft; # Added 2025-03-07
532533
ghostwriter = makePlasma5Throw "ghostwriter"; # Added 2023-03-18
533534
git-codeowners = throw "'git-codeowners' has been removed due to lack of upstream maintenance"; # Added 2025-01-25
534535
gmp5 = throw "'gmp5' has been removed as it is unmaintained. Consider using 'gmp' instead"; # Added 2024-10-28

0 commit comments

Comments
 (0)