diff --git a/pkgs/by-name/te/termshot/go-mod.patch b/pkgs/by-name/te/termshot/go-mod.patch deleted file mode 100644 index 5618ec24f8b2..000000000000 --- a/pkgs/by-name/te/termshot/go-mod.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff --git a/go.mod b/go.mod -index 6627fb1..a3397a9 100644 ---- a/go.mod -+++ b/go.mod -@@ -1,6 +1,6 @@ - module github.com/homeport/termshot - --go 1.20 -+go 1.22.0 - - require ( - github.com/creack/pty v1.1.23 diff --git a/pkgs/by-name/te/termshot/package.nix b/pkgs/by-name/te/termshot/package.nix index d3e580ae3244..b2cccc198b77 100644 --- a/pkgs/by-name/te/termshot/package.nix +++ b/pkgs/by-name/te/termshot/package.nix @@ -2,21 +2,22 @@ lib, fetchFromGitHub, buildGoModule, + testers, + termshot, + nix-update-script, }: buildGoModule rec { pname = "termshot"; - version = "0.2.12"; + version = "0.3.0"; src = fetchFromGitHub { owner = "homeport"; repo = "termshot"; - rev = "v${version}"; - hash = "sha256-ua2tFyOjLeqOpipLoSisASqwjqGEFdkxd2qHybZ1VDU="; + tag = "v${version}"; + hash = "sha256-vvSUdXVLuc3GmxPX9SzSeb8vbmqjhSLjXd9nmU7Q46g="; }; - vendorHash = "sha256-JweKjKvShiimFHQwRtoVuongWqqGIPcPz77qEVNec+M="; - - patches = [ ./go-mod.patch ]; + vendorHash = "sha256-nXAIU07SY/GdWZGASHXDg36cSGKw4elLOBDCoJk/xlU="; ldflags = [ "-s" @@ -24,9 +25,15 @@ buildGoModule rec { "-X github.com/homeport/termshot/internal/cmd.version=${version}" ]; + passthru = { + tests.version = testers.testVersion { package = termshot; }; + updateScript = nix-update-script { }; + }; + meta = { description = "Creates screenshots based on terminal command output"; homepage = "https://github.com/homeport/termshot"; + changelog = "https://github.com/homeport/termshot/releases/tag/v${version}"; license = lib.licenses.mit; maintainers = with lib.maintainers; [ defelo ]; mainProgram = "termshot";