How to locate a non-executable generated file?
I have a catkin package which generates a file—it's not an executable, but some scripts I have need to be able to locate and read this file. It ends up by default in the build space, and I've set up a POST_BUILD command in CMakeLists.txt to copy it to the devel space. The $(find) macro (and rospack find) point back to the source tree, so that's no good for locating this file, and it's not executable, so rosrun isn't the right choice either.
Incidentally, it works great in install space, as the generated file just gets copied into the package's share directory like any other resource, and then rospack find does its thing.
I believe the $(find-resource) macro as discussed here does what I want, but only in the context of launch files, not from the command line. I'd prefer not to have to wrap this script in a launch file unless absolutely necessary.
It looks like under the hood, find-resource is implemented using the catkin.find_in_workspaces.find_in_workspaces function. Is there a commandline interface to this, or should I just write my own small python wrapper to do it?
Thanks.