mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-20 13:37:28 +02:00
Make gArgs aware of the arguments
gArgs knows what the available arguments are and their help. Getting the help message is moved to gArgs and HelpMessage() is removed
This commit is contained in:
parent
08c1caf863
commit
4d4185a4f0
17 changed files with 345 additions and 310 deletions
|
|
@ -14,14 +14,11 @@ const std::string CBaseChainParams::MAIN = "main";
|
|||
const std::string CBaseChainParams::TESTNET = "test";
|
||||
const std::string CBaseChainParams::REGTEST = "regtest";
|
||||
|
||||
void AppendParamsHelpMessages(std::string& strUsage, bool debugHelp)
|
||||
void SetupChainParamsBaseOptions()
|
||||
{
|
||||
strUsage += HelpMessageGroup(_("Chain selection options:"));
|
||||
if (debugHelp) {
|
||||
strUsage += HelpMessageOpt("-regtest", "Enter regression test mode, which uses a special chain in which blocks can be solved instantly. "
|
||||
"This is intended for regression testing tools and app development.");
|
||||
}
|
||||
strUsage += HelpMessageOpt("-testnet", _("Use the test chain"));
|
||||
gArgs.AddArg("-regtest", "Enter regression test mode, which uses a special chain in which blocks can be solved instantly. "
|
||||
"This is intended for regression testing tools and app development.", true, OptionsCategory::CHAINPARAMS);
|
||||
gArgs.AddArg("-testnet", _("Use the test chain"), false, OptionsCategory::CHAINPARAMS);
|
||||
}
|
||||
|
||||
static std::unique_ptr<CBaseChainParams> globalChainBaseParams;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue