From 29f117d90a44811134d6450a73884bfb598480d4 Mon Sep 17 00:00:00 2001 From: natsukium Date: Fri, 3 Jan 2025 14:49:42 +0900 Subject: [PATCH 1/2] mactop: 0.1.9 -> 0.2.3 Diff: https://github.com/context-labs/mactop/compare/refs/tags/v0.1.9...v0.2.3 Changelog: https://github.com/context-labs/mactop/releases/tag/v0.2.3 --- pkgs/by-name/ma/mactop/package.nix | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pkgs/by-name/ma/mactop/package.nix b/pkgs/by-name/ma/mactop/package.nix index 660e642a33f61..54025548a0d4c 100644 --- a/pkgs/by-name/ma/mactop/package.nix +++ b/pkgs/by-name/ma/mactop/package.nix @@ -6,16 +6,16 @@ buildGoModule rec { pname = "mactop"; - version = "0.1.9"; + version = "0.2.3"; src = fetchFromGitHub { owner = "context-labs"; repo = "mactop"; - rev = "refs/tags/v${version}"; - hash = "sha256-r9je+oeedQJsFBWWbOUcUls/EX0JZveUkmsXXtC8O0Q="; + tag = "v${version}"; + hash = "sha256-xWUCOmNwhxmutY7G+FmxT7mabexuBIcgFzX++zsdnN4="; }; - vendorHash = "sha256-/KecVx4Gp776t8gFSO29E1q9v29nwrKIWZYCpj7IlSo="; + vendorHash = "sha256-BFvd1jJzGYsI2E6BdFy+BwHOAy7VgblcByV/oRCKORs="; ldflags = [ "-s" @@ -25,7 +25,7 @@ buildGoModule rec { meta = { description = "Terminal-based monitoring tool 'top' designed to display real-time metrics for Apple Silicon chips"; homepage = "https://github.com/context-labs/mactop"; - changelog = "https://github.com/context-labs/mactop/releases/tag/${lib.removePrefix "refs/tags/" src.rev}"; + changelog = "https://github.com/context-labs/mactop/releases/tag/${src.tag}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ natsukium ]; mainProgram = "mactop"; From 471bff0b46a6d43a1a7d0f87252cd42802f2076b Mon Sep 17 00:00:00 2001 From: natsukium Date: Fri, 3 Jan 2025 14:58:53 +0900 Subject: [PATCH 2/2] mactop: enable version check --- pkgs/by-name/ma/mactop/package.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pkgs/by-name/ma/mactop/package.nix b/pkgs/by-name/ma/mactop/package.nix index 54025548a0d4c..8cdc9432040eb 100644 --- a/pkgs/by-name/ma/mactop/package.nix +++ b/pkgs/by-name/ma/mactop/package.nix @@ -2,6 +2,7 @@ lib, buildGoModule, fetchFromGitHub, + versionCheckHook, }: buildGoModule rec { @@ -22,6 +23,10 @@ buildGoModule rec { "-w" ]; + doInstallCheck = true; + nativeInstallCheckInputs = [ versionCheckHook ]; + versionCheckProgramArg = [ "--version" ]; + meta = { description = "Terminal-based monitoring tool 'top' designed to display real-time metrics for Apple Silicon chips"; homepage = "https://github.com/context-labs/mactop";