gost: 3.0.0 -> 3.1.0; use finalAttrs; add updateScript; add maintainer moraxyc; add missing ldflags (#421691)

This commit is contained in:
Aleksana
2025-07-04 11:04:17 +08:00
committed by GitHub
+16 -6
View File
@@ -4,20 +4,27 @@
fetchFromGitHub,
buildGoModule,
versionCheckHook,
nix-update-script,
}:
buildGoModule rec {
buildGoModule (finalAttrs: {
pname = "gost";
version = "3.0.0";
version = "3.1.0";
src = fetchFromGitHub {
owner = "go-gost";
repo = "gost";
tag = "v${version}";
hash = "sha256-ep3ZjD+eVKl3PuooDuYeur8xDAcyy6ww2I7f3cYG03o=";
tag = "v${finalAttrs.version}";
hash = "sha256-4ZfGxhXespaZNspvbwZ/Yz2ncqtY3wxJPQsqVILayao=";
};
vendorHash = "sha256-lzyr6Q8yXsuer6dRUlwHEeBewjwGxDslueuvIiZUW70=";
vendorHash = "sha256-lWuLvYF9Sl+k8VnsujvRmj7xb9zst+g//Gkg7VwtWkg=";
# Based on ldflags in upstream's .goreleaser.yaml
ldflags = [
"-s"
"-X main.version=v${finalAttrs.version}"
];
__darwinAllowLocalNetworking = true;
@@ -30,6 +37,8 @@ buildGoModule rec {
versionCheckProgramArg = "-V";
passthru.updateScript = nix-update-script { };
meta = {
description = "Simple tunnel written in golang";
homepage = "https://github.com/go-gost/gost";
@@ -37,7 +46,8 @@ buildGoModule rec {
maintainers = with lib.maintainers; [
pmy
ramblurr
moraxyc
];
mainProgram = "gost";
};
}
})