go-packages: Fix version string output
This commit is contained in:
parent
71ec4dbd45
commit
a403f130b6
@ -8,7 +8,7 @@ let
|
|||||||
|
|
||||||
buildFromGitHub = { rev, date ? null, owner, repo, sha256, name ? repo, goPackagePath ? "github.com/${owner}/${repo}", ... }@args: buildGoPackage (args // {
|
buildFromGitHub = { rev, date ? null, owner, repo, sha256, name ? repo, goPackagePath ? "github.com/${owner}/${repo}", ... }@args: buildGoPackage (args // {
|
||||||
inherit rev goPackagePath;
|
inherit rev goPackagePath;
|
||||||
name = "${name}-${if date != null then date else stdenv.lib.strings.substring 0 7 rev}";
|
name = "${name}-${if date != null then date else if builtins.stringLength rev != 40 then rev else stdenv.lib.strings.substring 0 7 rev}";
|
||||||
src = fetchFromGitHub { inherit rev owner repo sha256; };
|
src = fetchFromGitHub { inherit rev owner repo sha256; };
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user