Skip to content

Commit 6853db3

Browse files
committed
add option to toggle node settings off
1 parent 10582b5 commit 6853db3

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

hydra_ros/app/hydra_node.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@
4848
namespace hydra {
4949

5050
struct RunSettings {
51+
bool show_run_settings = true;
5152
size_t robot_id = 0;
5253
bool exit_after_clock = false;
5354
bool force_shutdown = false;
@@ -63,6 +64,7 @@ struct RunSettings {
6364
void declare_config(RunSettings& config) {
6465
using namespace config;
6566
name("RunSettings");
67+
field(config.show_run_settings, "show_run_settings");
6668
field(config.robot_id, "robot_id");
6769
field(config.exit_after_clock, "exit_after_clock");
6870
field(config.force_shutdown, "force_shutdown");
@@ -133,7 +135,9 @@ int main(int argc, char* argv[]) {
133135
}
134136

135137
config::Settings().setLogger("glog");
136-
LOG(INFO) << "Using node settings\n" << config::toString(settings);
138+
if (settings.show_run_settings) {
139+
LOG(INFO) << "Using node settings\n" << config::toString(settings);
140+
}
137141

138142
[[maybe_unused]] const auto plugins = config::loadExternalFactories(settings.paths);
139143

0 commit comments

Comments
 (0)