diff options
Diffstat (limited to 'nixpkgs/pkgs/tools/misc/mmctl/default.nix')
-rw-r--r-- | nixpkgs/pkgs/tools/misc/mmctl/default.nix | 26 |
1 files changed, 18 insertions, 8 deletions
diff --git a/nixpkgs/pkgs/tools/misc/mmctl/default.nix b/nixpkgs/pkgs/tools/misc/mmctl/default.nix index 7084ef0acb11..197d145fc6c7 100644 --- a/nixpkgs/pkgs/tools/misc/mmctl/default.nix +++ b/nixpkgs/pkgs/tools/misc/mmctl/default.nix @@ -5,29 +5,39 @@ buildGoModule rec { pname = "mmctl"; - version = "7.10.5"; + version = "9.2.2"; src = fetchFromGitHub { owner = "mattermost"; - repo = "mmctl"; + repo = "mattermost"; rev = "v${version}"; - sha256 = "sha256-FQdxFvYJ+YrOc1p3/Ju3ZOGFH32WeZjHXtsIYG+O0U0="; - }; + hash = "sha256-53L2F20vaLLxtQS3DP/u0ZxLtnXHmjfcOMbXd4i+A6Y="; + } + "/server"; + + vendorHash = "sha256-v8aKZyb4emrwuIgSBDgla5wzwyt6PVGakbXjB9JVaCk="; + + patches = [ ./0001-module-replace-public.patch ]; - vendorHash = null; + subPackages = [ "cmd/mmctl" ]; - checkPhase = "make test"; + checkPhase = "go test -tags unit -timeout 30m ./cmd/mmctl/..."; ldflags = [ "-s" "-w" - "-X github.com/mattermost/mmctl/v6/commands.Version=${version}" + "-X github.com/mattermost/mattermost/server/public/model.Version=${version}" + "-X github.com/mattermost/mattermost/server/public/model.BuildNumber=${version}-nixpkgs" + "-X github.com/mattermost/mattermost/server/public/model.BuildDate=1970-01-01" + "-X github.com/mattermost/mattermost/server/public/model.BuildHash=v${version}" + "-X github.com/mattermost/mattermost/server/public/model.BuildHashEnterprise=none" + "-X github.com/mattermost/mattermost/server/public/model.BuildEnterpriseReady=false" ]; meta = with lib; { description = "A remote CLI tool for Mattermost"; homepage = "https://github.com/mattermost/mmctl"; license = licenses.asl20; - maintainers = with maintainers; [ ppom ]; + maintainers = with maintainers; [ ppom mgdelacroix ]; + mainProgram = "mmctl"; }; } |