1{ lib
2, buildGoModule
3, fetchFromGitHub
4}:
5
6buildGoModule rec {
7 pname = "auth0-cli";
8 version = "1.0.1";
9
10 src = fetchFromGitHub {
11 owner = "auth0";
12 repo = "auth0-cli";
13 rev = "v${version}";
14 hash = "sha256-mOG7N7+qmAw+D6Bp0QtyS3oualDD/fffDVCuidLJ+Pw=";
15 };
16
17 vendorHash = "sha256-8t5qnHaZeZUxdk5DmIfOx86Zk9c9hJuxHjE6upqC638=";
18
19 ldflags = [
20 "-s" "-w"
21 "-X github.com/auth0/auth0-cli/internal/buildinfo.Version=v${version}"
22 "-X github.com/auth0/auth0-cli/internal/buildinfo.Revision=0000000"
23 ];
24
25 preCheck = ''
26 # Feed in all tests for testing
27 # This is because subPackages above limits what is built to just what we
28 # want but also limits the tests
29 unset subPackages
30 '';
31
32 subPackages = [ "cmd/auth0" ];
33
34 meta = with lib; {
35 description = "Supercharge your developer workflow";
36 homepage = "https://auth0.github.io/auth0-cli";
37 changelog = "https://github.com/auth0/auth0-cli/releases/tag/v${version}";
38 license = licenses.mit;
39 maintainers = with maintainers; [ matthewcroughan ];
40 mainProgram = "auth0";
41 };
42}