# (Conveniently) deleting packages using rosinstall/rosws

For a large project, we use a combination of a catkin workspace and a rosbuild one (with the rosbuild one getting initialized from the catkin one). Adding new packages to either of those workspaces is convenient and easy, by just adding to the corresponding rosinstall file and running an update script.

We now have a case where a package has been catkinized, which means it has to be migrated from the rosbuild to the catkin workspace. As mentioned, adding it to the catkin workspace is easy, by just adding it to the rosinstall file. Is there a similarly easy way to remove a package from the rosbuild workspace? The way I know is by running

rosws/wstool rm [PATH_TO_PACKAGE]


and performing a manual

rm [PATH_TO_PACKAGE] -rf


afterwards. That's pretty straightforward for performing it on a single machine, but when multiple/many people are working on a project, cluttering update scripts with this kind of additional commands for removal of old stuff quickly gets ugly. I suppose the most convenient option would be to be able to specify this kind of thing also in a rosinstall file, although that certainly is not without problems either.

Any hints on how to perform selective delete operations on workspaces in a more elegant way are welcome :)

edit retag close merge delete

Sort by » oldest newest most voted

For the rosws workspace each folder is whitelisted into the ROS_PACKAGE_PATH based on the .rosinstall file. If you remove an entry from the .rosinstall file, and then share it with someone, they can run rosws regenerate to get new setup.*sh files which will not add the removed entry's folder to the ROS_PACKAGE_PATH.

For catkin, you'll have to rm -rf the folder or touch src/pkg_to_ignore/CATKIN_IGNORE.

more