1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
source ../common.sh
clearStore
evil=$(cat <<-'EOF'
builtins.derivation {
name = "evil-kbity";
system = "x86_64-darwin";
builder = "/bin/sh";
args = [ "-c" "> $out" ];
__structuredAttrs = true;
env.oops = "lol %s";
}
EOF
)
# This should not crash
nix-shell --expr "$evil" --run 'echo yay' | grepQuiet yay
|