You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
270 B
15 lines
270 B
2 years ago
|
set -e
|
||
2 years ago
|
|
||
|
test_dir="$(mktemp -d)"
|
||
2 years ago
|
trap "rm -rf $test_dir" EXIT
|
||
2 years ago
|
|
||
|
mkdir -p "$test_dir"/run
|
||
|
mkdir -p "$test_dir"/data
|
||
|
|
||
|
test_cfg="(import ./config.nix) // {
|
||
|
runDir=\"${test_dir}/run\";
|
||
|
dataDir=\"${test_dir}/data\";
|
||
|
}"
|
||
|
|
||
2 years ago
|
nix-shell -A shell --arg config "$test_cfg" "$@"
|