Merge pull request #168286 from liff/dsq/add-version-on-build

dsq: pass version to the build
main
Guillaume Girol 2 years ago committed by GitHub
commit 2073659a0f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      pkgs/tools/misc/dsq/default.nix

@ -5,6 +5,7 @@
, runCommand
, nix-update-script
, dsq
, testVersion
, diffutils
}:
@ -23,10 +24,14 @@ buildGoModule rec {
nativeBuildInputs = [ diffutils ];
ldflags = [ "-X" "main.Version=${version}" ];
passthru = {
updateScript = nix-update-script { attrPath = pname; };
tests = {
version = testVersion { package = dsq; };
pretty-csv = runCommand "${pname}-test" { } ''
mkdir "$out"
cat <<EOF > "$out/input.csv"

Loading…
Cancel
Save