mirror of
https://github.com/Xahau/xahaud.git
synced 2025-12-06 17:27:52 +00:00
Add --version command line option
This commit is contained in:
@@ -281,6 +281,7 @@ int RippleMain::run (int argc, char const* const* argv)
|
||||
("net", "Get the initial ledger from the network.")
|
||||
("fg", "Run in the foreground.")
|
||||
("import", importDescription.toStdString ().c_str ())
|
||||
("version", "Display the build version.")
|
||||
;
|
||||
|
||||
// Interpret positional arguments as --parameters.
|
||||
@@ -334,6 +335,13 @@ int RippleMain::run (int argc, char const* const* argv)
|
||||
iResult = 1;
|
||||
}
|
||||
|
||||
if (vm.count ("version"))
|
||||
{
|
||||
String const& s (BuildInfo::getVersionString ());
|
||||
std::cout << "rippled version " << s.toStdString() << std::endl;
|
||||
return 0;
|
||||
}
|
||||
|
||||
// Use a watchdog process unless we're invoking a stand alone type of mode
|
||||
//
|
||||
if (HaveSustain ()
|
||||
|
||||
Reference in New Issue
Block a user