platinum-searcher: use buildGoModule
This commit is contained in:
parent
43bad2a819
commit
8681edfaa7
2 changed files with 15 additions and 91 deletions
|
@ -1,20 +1,27 @@
|
||||||
{ lib, buildGoPackage, fetchFromGitHub }:
|
{ lib, buildGoModule, fetchFromGitHub, fetchpatch }:
|
||||||
|
|
||||||
buildGoPackage rec {
|
buildGoModule rec {
|
||||||
pname = "the_platinum_searcher";
|
pname = "the_platinum_searcher";
|
||||||
version = "2.1.5";
|
version = "2.1.5";
|
||||||
rev = "v${version}";
|
|
||||||
|
|
||||||
goPackagePath = "github.com/monochromegane/the_platinum_searcher";
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
inherit rev;
|
|
||||||
owner = "monochromegane";
|
owner = "monochromegane";
|
||||||
repo = "the_platinum_searcher";
|
repo = "the_platinum_searcher";
|
||||||
sha256 = "1y7kl3954dimx9hp2bf1vjg1h52hj1v6cm4f5nhrqzwrawp0b6q0";
|
rev = "v${version}";
|
||||||
|
hash = "sha256-AJsFLleZf5yhLY5UZnaQUBQYntzBLXFh6jU2UtKg8/g=";
|
||||||
};
|
};
|
||||||
|
|
||||||
goDeps = ./deps.nix;
|
vendorHash = "sha256-GIjPgu0e+duN5MeWcRaF5xUFCkqe2aZJCwGbLUMko08=";
|
||||||
|
|
||||||
|
patches = [
|
||||||
|
# Add Go Modules support. See https://github.com/monochromegane/the_platinum_searcher/pull/217.
|
||||||
|
(fetchpatch {
|
||||||
|
url = "https://github.com/monochromegane/the_platinum_searcher/pull/217/commits/69064d11c57d5fd5f66ddd95f0e789786183d3c6.patch";
|
||||||
|
hash = "sha256-qQ7kZYb2MWSUV6T1frIPT9nMfb20SI7lbG8YhqyQEi8=";
|
||||||
|
})
|
||||||
|
];
|
||||||
|
|
||||||
|
ldflags = [ "-s" "-w" ];
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
homepage = "https://github.com/monochromegane/the_platinum_searcher";
|
homepage = "https://github.com/monochromegane/the_platinum_searcher";
|
||||||
|
|
83
pkgs/tools/text/platinum-searcher/deps.nix
generated
83
pkgs/tools/text/platinum-searcher/deps.nix
generated
|
@ -1,83 +0,0 @@
|
||||||
[
|
|
||||||
{
|
|
||||||
goPackagePath = "gopkg.in/yaml.v2";
|
|
||||||
fetch = {
|
|
||||||
type = "git";
|
|
||||||
url = "https://gopkg.in/yaml.v2";
|
|
||||||
rev = "a5b47d31c556af34a302ce5d659e6fea44d90de0";
|
|
||||||
sha256 = "0v6l48fshdjrqzyq1kwn22gy7vy434xdr1i0lm3prsf6jbln9fam";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
goPackagePath = "github.com/jessevdk/go-flags";
|
|
||||||
fetch = {
|
|
||||||
type = "git";
|
|
||||||
url = "https://github.com/jessevdk/go-flags";
|
|
||||||
rev = "4e64e4a4e2552194cf594243e23aa9baf3b4297e";
|
|
||||||
sha256 = "02x7f1wm8119s27h4dc3a4aw6shydnpnnkvzwg5xm0snn5kb4zxm";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
goPackagePath = "github.com/BurntSushi/toml";
|
|
||||||
fetch = {
|
|
||||||
type = "git";
|
|
||||||
url = "https://github.com/BurntSushi/toml";
|
|
||||||
rev = "99064174e013895bbd9b025c31100bd1d9b590ca";
|
|
||||||
sha256 = "058qrar8rvw3wb0ci1mf1axnqq2729cvv9zmdr4ms2nn9s97yiz9";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
goPackagePath = "golang.org/x/text";
|
|
||||||
fetch = {
|
|
||||||
type = "git";
|
|
||||||
url = "https://go.googlesource.com/text";
|
|
||||||
rev = "a49bea13b776691cb1b49873e5d8df96ec74831a";
|
|
||||||
sha256 = "1pcmgf88wml6ca8v63nh3nxsfvpzjv3c4qj2w2wkizbil826g7as";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
goPackagePath = "github.com/monochromegane/conflag";
|
|
||||||
fetch = {
|
|
||||||
type = "git";
|
|
||||||
url = "https://github.com/monochromegane/conflag";
|
|
||||||
rev = "6d68c9aa4183844ddc1655481798fe4d90d483e9";
|
|
||||||
sha256 = "0csfr5c8d3kbna9sqhzfp2z06wq6mc6ijja1zj2i82kzsq8534wa";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
goPackagePath = "github.com/monochromegane/go-home";
|
|
||||||
fetch = {
|
|
||||||
type = "git";
|
|
||||||
url = "https://github.com/monochromegane/go-home";
|
|
||||||
rev = "25d9dda593924a11ea52e4ffbc8abdb0dbe96401";
|
|
||||||
sha256 = "172chakrj22xfm0bcda4qj5zqf7lwr53pzwc3xj6wz8vd2bcxkww";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
goPackagePath = "github.com/monochromegane/terminal";
|
|
||||||
fetch = {
|
|
||||||
type = "git";
|
|
||||||
url = "https://github.com/monochromegane/terminal";
|
|
||||||
rev = "2da212063ce19aed90ee5bbb00ad1ad7393d7f48";
|
|
||||||
sha256 = "1rddaq9pk5q57ildms35iihghqk505gb349pb0f6k3svchay38nh";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
goPackagePath = "github.com/monochromegane/go-gitignore";
|
|
||||||
fetch = {
|
|
||||||
type = "git";
|
|
||||||
url = "https://github.com/monochromegane/go-gitignore";
|
|
||||||
rev = "38717d0a108ca0e5af632cd6845ca77d45b50729";
|
|
||||||
sha256 = "0r1inabpgg6sn6i47b02hcmd2p4dc1ab1mcy20mn1b2k3mpdj4b7";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
goPackagePath = "github.com/shiena/ansicolor";
|
|
||||||
fetch = {
|
|
||||||
type = "git";
|
|
||||||
url = "https://github.com/shiena/ansicolor";
|
|
||||||
rev = "a422bbe96644373c5753384a59d678f7d261ff10";
|
|
||||||
sha256 = "1dcn8a9z6a5dxa2m3fkppnajcls8lanbl38qggkf646yi5qsk1hc";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
]
|
|
Loading…
Reference in a new issue