How do I retrieve the current package name from a cpp node?
ros::this_node::getName()
allows me to know in which node my code is running but there is no package equivalent that would look lile ros::this_package::getName()
.
I would like to be able to programmatically know in which package my code is running.
Is there a solution or work-around?
If it would be OK to get a hardcoded reference (ie: not something resolved at runtime), then perhaps my answer to #q341432 could be useful.