1 { buildGoModule, fetchFromGitHub, installShellFiles, lib }:
7 src = fetchFromGitHub {
11 sha256 = "sha256-nR9+6glX0oUJZq32XxyV4aVjfjVlNycZvMNaVHy+Q1s=";
14 vendorHash = "sha256-kFmoNd40YxUXVXk0F1Bf77KS5AM0jjOTwTjM5pYKkv4=";
18 nativeBuildInputs = [ installShellFiles ];
20 subPackages = [ "." ];
23 export HOME=$(mktemp -d)
27 "-X main.version=${version}"
28 "-X main.apiVersion=1.0"
29 "-X github.com/dapr/cli/pkg/standalone.gitcommit=${src.rev}"
30 "-X github.com/dapr/cli/pkg/standalone.gitversion=${version}"
34 mv $out/bin/cli $out/bin/dapr
36 installShellCompletion --cmd dapr \
37 --bash <($out/bin/dapr completion bash) \
38 --zsh <($out/bin/dapr completion zsh)
42 description = "A CLI for managing Dapr, the distributed application runtime";
43 homepage = "https://dapr.io";
44 license = licenses.asl20;
45 maintainers = with maintainers; [ joshvanl lucperkins ];