forked from lix-project/lix
edef
c65a6fa86a
Having a colon in the path may cause issues, and having the hash function indicated isn't actually necessary. We now verify the path format in the tests to prevent regressions.
19 lines
396 B
Bash
19 lines
396 B
Bash
source common.sh
|
|
|
|
clearStore
|
|
|
|
outPath=$(nix-build --no-out-link -E "
|
|
with import ./config.nix;
|
|
|
|
mkDerivation {
|
|
name = \"pass-as-file\";
|
|
passAsFile = [ \"foo\" ];
|
|
foo = [ \"xyzzy\" ];
|
|
builder = builtins.toFile \"builder.sh\" ''
|
|
[ \"\$(basename \$fooPath)\" = .attr-1bp7cri8hplaz6hbz0v4f0nl44rl84q1sg25kgwqzipzd1mv89ic ]
|
|
[ \"\$(cat \$fooPath)\" = xyzzy ]
|
|
touch \$out
|
|
'';
|
|
}
|
|
")
|