mirror of
https://github.com/XRPLF/rippled.git
synced 2025-11-21 03:26:01 +00:00
Add [features] section to .cfg:
This non-production config section allows features to be enabled
by listing their text descriptions, one line each, in the config
section titled "features".
NOTE: Feature names with leading or trailing whitespace, or
containing an equals sign ('=') are not supported.
This commit is contained in:
committed by
Edward Hennis
parent
2ec40cb6f1
commit
d49f9ea109
@@ -22,6 +22,7 @@
|
||||
#include <ripple/core/ConfigSections.h>
|
||||
#include <ripple/basics/Log.h>
|
||||
#include <ripple/json/json_reader.h>
|
||||
#include <ripple/protocol/Feature.h>
|
||||
#include <ripple/protocol/SystemParameters.h>
|
||||
#include <ripple/net/HTTPClient.h>
|
||||
#include <beast/http/URL.h>
|
||||
@@ -553,6 +554,12 @@ void Config::loadFromString (std::string const& fileContents)
|
||||
|
||||
if (getSingleSection (secConfig, SECTION_DEBUG_LOGFILE, strTemp))
|
||||
DEBUG_LOGFILE = strTemp;
|
||||
|
||||
{
|
||||
auto const part = section("features");
|
||||
for(auto const& s : part.values())
|
||||
features.insert(feature(s));
|
||||
}
|
||||
}
|
||||
|
||||
int Config::getSize (SizedItemName item) const
|
||||
|
||||
Reference in New Issue
Block a user