For testing purposes, I am running Gazebo sim (i.e. 'new Gazebo') with logging enabled:
gz sim -v 4 world.sdf
This works, but there's a lot of irrelevant debug output (e.g. gui, simulationrunner, SystemManager, etc).
Is there a way to filter the log output?
In other words: is there an equivalent command for Gazebo sim, to following ROS 2 command:
ros2 run <package> <executable> --ros-args --log-level DEBUG --log-level rcl:=INFO
which configures loglevel 'debug' for all loggers, except for the rcl logger which gets loglevel 'info' (and hence does not output (many) messages).
std::coutinstead ofgzdbgsince the whitecoutoutput contrasts with the other (colored) messages. Another possibility (which I did not try) could be to use bash color codes in the log messages. – JRTG Aug 05 '23 at 18:32