mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-23 06:26:15 +02:00
41ec982f31
approach. This makes it much easier to add extra complexity in the normaliser / realiser (e.g., build hooks, substitutes).
20 lines
418 B
Bash
20 lines
418 B
Bash
echo "NIX_STORE_DIR=$NIX_STORE_DIR NIX_DB_DIR=$NIX_DB_DIR"
|
|
|
|
test -n "$TEST_ROOT"
|
|
if test -d "$TEST_ROOT"; then
|
|
chmod -R u+w "$TEST_ROOT"
|
|
rm -rf "$TEST_ROOT"
|
|
fi
|
|
mkdir "$TEST_ROOT"
|
|
|
|
mkdir "$NIX_STORE_DIR"
|
|
mkdir "$NIX_DATA_DIR"
|
|
mkdir "$NIX_LOG_DIR"
|
|
mkdir "$NIX_STATE_DIR"
|
|
mkdir "$NIX_DB_DIR"
|
|
|
|
# Initialise the database.
|
|
$TOP/src/nix-store/nix-store --init
|
|
|
|
# Did anything happen?
|
|
test -e "$NIX_DB_DIR"/validpaths
|