diff options
author | Lassulus <github@lassul.us> | 2020-12-28 17:34:18 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-12-28 17:34:18 +0100 |
commit | 4b210ca92afaba35a2f17bbd1db534f33ffa1d9f (patch) | |
tree | ba75a2539b18f697429bec514a17de10cc620a59 /pkgs/applications/misc/dasel | |
parent | b90c5cb703da946f53097bc8c7fb1a5acd09c701 (diff) | |
parent | 51031a8d73007115dd5ba9b71449483704699685 (diff) |
Merge pull request #107282 from 0x4A6F/master-dasel
dasel: add installCheckPhase test
Diffstat (limited to 'pkgs/applications/misc/dasel')
-rw-r--r-- | pkgs/applications/misc/dasel/default.nix | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/pkgs/applications/misc/dasel/default.nix b/pkgs/applications/misc/dasel/default.nix index 073983fa3551..8853ff266a6a 100644 --- a/pkgs/applications/misc/dasel/default.nix +++ b/pkgs/applications/misc/dasel/default.nix @@ -20,6 +20,17 @@ buildGoModule rec { -ldflags=-s -w -X github.com/tomwright/dasel/internal.Version=${version} ''; + doInstallCheck = true; + installCheckPhase = '' + if [[ "$("$out/bin/${pname}" --version)" == "${pname} version ${version}" ]]; then + echo "" | $out/bin/dasel put object -p yaml -t string -t int "my.favourites" colour=red number=3 | grep -q red + echo '${pname} smoke check passed' + else + echo '${pname} smoke check failed' + return 1 + fi + ''; + meta = with stdenv.lib; { description = "Query and update data structures from the command line"; longDescription = '' |