2023-01-25 10:53:49 +00:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub, fetchpatch }:
|
2017-04-16 12:37:53 +00:00
|
|
|
|
2023-01-25 10:53:49 +00:00
|
|
|
buildGoModule rec {
|
2019-08-15 12:41:18 +00:00
|
|
|
pname = "gdrive";
|
2023-01-25 10:53:49 +00:00
|
|
|
version = "2.1.1";
|
2017-04-16 12:37:53 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2023-01-25 10:53:49 +00:00
|
|
|
owner = "prasmussen";
|
|
|
|
repo = "gdrive";
|
|
|
|
rev = version;
|
|
|
|
hash = "sha256-2dJmGFHfGSroucn4WgiV2NExBs5wtMDe2kX1jDBwbRs=";
|
2017-04-16 12:37:53 +00:00
|
|
|
};
|
|
|
|
|
2023-01-25 10:53:49 +00:00
|
|
|
deleteVendor = true;
|
|
|
|
vendorHash = "sha256-sHNP1YwnZYu0UfgLx5+gxJmesY8Brt7rr9cptlyk9Bk=";
|
|
|
|
|
|
|
|
patches = [
|
|
|
|
# Add Go Modules support
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/prasmussen/gdrive/pull/585/commits/faa6fc3dc104236900caa75eb22e9ed2e5ecad42.patch";
|
|
|
|
hash = "sha256-W8o2ZfhQFJISHfPavjx9sw5UB6xOZ7qRW4L0bHNddS8=";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
|
|
|
ldflags = [ "-s" "-w" ];
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2023-01-25 10:53:49 +00:00
|
|
|
homepage = "https://github.com/prasmussen/gdrive";
|
2017-04-16 12:37:53 +00:00
|
|
|
description = "A command line utility for interacting with Google Drive";
|
2023-01-25 10:53:49 +00:00
|
|
|
license = licenses.mit;
|
2017-04-16 12:37:53 +00:00
|
|
|
maintainers = [ maintainers.rzetterberg ];
|
|
|
|
};
|
|
|
|
}
|