2022-02-20 05:27:41 +00:00
|
|
|
{ lib
|
2022-06-16 17:23:12 +00:00
|
|
|
, stdenv
|
2022-02-20 05:27:41 +00:00
|
|
|
, pkg-config
|
|
|
|
, fetchFromGitHub
|
|
|
|
, buildGoModule
|
|
|
|
, btrfs-progs
|
|
|
|
, gpgme
|
2022-03-30 09:31:56 +00:00
|
|
|
, libassuan
|
2022-02-20 05:27:41 +00:00
|
|
|
, lvm2
|
2022-04-27 09:35:20 +00:00
|
|
|
, testers
|
2022-03-30 09:31:56 +00:00
|
|
|
, podman-tui
|
2022-02-20 05:27:41 +00:00
|
|
|
}:
|
|
|
|
buildGoModule rec {
|
|
|
|
pname = "podman-tui";
|
2022-10-21 18:38:19 +00:00
|
|
|
version = "0.6.0";
|
2022-02-20 05:27:41 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "containers";
|
|
|
|
repo = "podman-tui";
|
|
|
|
rev = "v${version}";
|
2022-10-21 18:38:19 +00:00
|
|
|
sha256 = "sha256-9ZFyrRf4yMik4+TQYN+75fWuKHuI8hkaKJ6o5qWYb7E=";
|
2022-02-20 05:27:41 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
vendorSha256 = null;
|
|
|
|
|
|
|
|
nativeBuildInputs = [ pkg-config ];
|
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
buildInputs = [ gpgme libassuan ]
|
|
|
|
++ lib.optionals stdenv.isLinux [ btrfs-progs lvm2 ];
|
2022-02-20 05:27:41 +00:00
|
|
|
|
|
|
|
ldflags = [ "-s" "-w" ];
|
|
|
|
|
2022-10-21 18:38:19 +00:00
|
|
|
preCheck =
|
|
|
|
let skippedTests = [
|
|
|
|
"TestNetdialogs"
|
|
|
|
]; in
|
|
|
|
''
|
|
|
|
export HOME=/home/$(whoami)
|
|
|
|
|
|
|
|
# Disable flaky tests
|
|
|
|
buildFlagsArray+=("-run" "[^(${builtins.concatStringsSep "|" skippedTests})]")
|
|
|
|
'';
|
2022-08-12 12:06:08 +00:00
|
|
|
|
2022-04-27 09:35:20 +00:00
|
|
|
passthru.tests.version = testers.testVersion {
|
2022-03-30 09:31:56 +00:00
|
|
|
package = podman-tui;
|
|
|
|
command = "podman-tui version";
|
|
|
|
version = "v${version}";
|
|
|
|
};
|
2022-02-20 05:27:41 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://github.com/containers/podman-tui";
|
|
|
|
description = "Podman Terminal UI";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ aaronjheng ];
|
|
|
|
};
|
|
|
|
}
|