How do I retrieve the current package name from a cpp node?

asked 2017-02-10 06:59:48 -0500

VictorLamoine gravatar image

updated 2017-02-10 11:15:39 -0500

gvdhoorn gravatar image

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?

edit retag flag offensive close merge delete