Add nested namespace to nodes
Hi,
I have an application where two nodes are created.
/app_ns/first_node
/second_node
As you can see, I'm specifying a namespace for one of the nodes, while the other has the default ""
.
My goal, as the title says, is to add a namespace to both nodes, for example via command-line, but I'm open to other approaches.
What I would like to get is
/user_ns/app_ns/first_node
/user_ns/second_node
Unfortunately, the only way I know for specifying namespace is through the remapping arguments, which does not work in this case. For example I tried the following
$ ros2 run my_pkg my_app -r __ns:=/user_ns
$ ros2 node list
/user_ns/first_node
/user_ns/second_node
Do you know how could I get my desired output? I.e. how can I add/prepend a namespace while keeping whatever namespace the executable is already setting? Thank you