nix-bundle/test.sh
zimbatm 33b7756441
fixes #68
The logic wasn't quite right in #67.

I also added a ./test.sh to check for both use-cases.
2020-11-29 13:29:02 +01:00

11 lines
274 B
Bash
Executable File

#!/usr/bin/env bash
set -euo pipefail
export NIX_PATH=channel:nixos-20.09
echo "Test with attribute name"
./nix-bundle.sh hello /bin/hello
echo "Test with store path"
out=$(nix-build --no-out-link --expr '(import <nixpkgs> {})' -A hello)
./nix-bundle.sh "$out" /bin/hello