1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-10 04:43:53 +02:00

Remove $NIX_DB_DIR

This variable has no reason to exist, given $NIX_STATE_DIR.
This commit is contained in:
Eelco Dolstra 2016-07-27 17:14:41 +02:00
parent be64fbb501
commit 2fad86f361
12 changed files with 11 additions and 30 deletions

View file

@ -252,7 +252,6 @@ void printVersion(const string & programName)
std::cout << "Configuration file: " << settings.nixConfDir + "/nix.conf" << "\n";
std::cout << "Store directory: " << settings.nixStore << "\n";
std::cout << "State directory: " << settings.nixStateDir << "\n";
std::cout << "Database directory: " << settings.nixDBPath << "\n";
}
throw Exit();
}

View file

@ -69,7 +69,6 @@ void Settings::processEnvironment()
nixDataDir = canonPath(getEnv("NIX_DATA_DIR", NIX_DATA_DIR));
nixLogDir = canonPath(getEnv("NIX_LOG_DIR", NIX_LOG_DIR));
nixStateDir = canonPath(getEnv("NIX_STATE_DIR", NIX_STATE_DIR));
nixDBPath = getEnv("NIX_DB_DIR", nixStateDir + "/db");
nixConfDir = canonPath(getEnv("NIX_CONF_DIR", NIX_CONF_DIR));
nixLibexecDir = canonPath(getEnv("NIX_LIBEXEC_DIR", NIX_LIBEXEC_DIR));
nixBinDir = canonPath(getEnv("NIX_BIN_DIR", NIX_BIN_DIR));

View file

@ -51,9 +51,6 @@ struct Settings {
/* The directory where state is stored. */
Path nixStateDir;
/* The directory where we keep the SQLite database. */
Path nixDBPath;
/* The directory where configuration files are stored. */
Path nixConfDir;

View file

@ -39,7 +39,7 @@ namespace nix {
LocalStore::LocalStore(const Params & params)
: LocalFSStore(params)
, realStoreDir(get(params, "real", storeDir))
, dbDir(get(params, "state", "") != "" ? get(params, "state", "") + "/db" : settings.nixDBPath)
, dbDir(stateDir + "/db")
, linksDir(realStoreDir + "/.links")
, reservedPath(dbDir + "/reserved")
, schemaPath(dbDir + "/schema")