2015-02-17 13:42:15 +00:00
|
|
|
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\" ''
|
2020-01-02 23:41:48 +00:00
|
|
|
[ \"\$(basename \$fooPath)\" = .attr-1bp7cri8hplaz6hbz0v4f0nl44rl84q1sg25kgwqzipzd1mv89ic ]
|
2015-02-17 15:42:54 +00:00
|
|
|
[ \"\$(cat \$fooPath)\" = xyzzy ]
|
2015-02-17 13:42:15 +00:00
|
|
|
touch \$out
|
|
|
|
'';
|
|
|
|
}
|
|
|
|
")
|