mirror of
https://github.com/NixOS/nix
synced 2025-07-06 17:31:47 +02:00
Move applyConfigFile to lambda inside libstore
This commit is contained in:
parent
e4cbdd26e0
commit
d6898cd58b
3 changed files with 9 additions and 16 deletions
|
@ -165,14 +165,6 @@ void AbstractConfig::applyConfig(const std::string & contents, const std::string
|
|||
set(name, value);
|
||||
}
|
||||
|
||||
void AbstractConfig::applyConfigFile(const Path & path)
|
||||
{
|
||||
try {
|
||||
std::string contents = readFile(path);
|
||||
applyConfig(contents, path);
|
||||
} catch (SysError &) { }
|
||||
}
|
||||
|
||||
void Config::resetOverridden()
|
||||
{
|
||||
for (auto & s : _settings)
|
||||
|
|
|
@ -82,12 +82,6 @@ public:
|
|||
*/
|
||||
void applyConfig(const std::string & contents, const std::string & path = "<unknown>");
|
||||
|
||||
/**
|
||||
* Applies a nix configuration file
|
||||
* - path: the location of the config file to apply
|
||||
*/
|
||||
void applyConfigFile(const Path & path);
|
||||
|
||||
/**
|
||||
* Resets the `overridden` flag of all Settings
|
||||
*/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue