colcon-package-selection is an extension for colcon, a build tool primarily used in the Robot Operating System (ROS) ecosystem, to allow users to precisely select which packages should be processed during build, test, or install operations. It enhances colcon's core functionality by providing command-line arguments for including or excluding packages based on names or dependencies. The current version is 0.2.10. It follows the colcon core release cadence, typically tied to ROS releases or when new features/fixes are required.
pip install colcon-package-selectionVerified import paths — ran on the pinned version, not inferred.
Demonstrates building a single package (`my_robot_pkg`) and its direct dependencies using `--packages-select`. This is the primary way to interact with `colcon-package-selection`. Ensure `colcon-package-selection` is installed and your `my_robot_pkg` is discoverable in the current workspace.
Switch from `colcon build --packages-select PKG` to `colcon build --packages-up-to PKG` when a full dependency chain build is desired.
Review your `colcon` command line for conflicting package selection arguments. Ensure `--packages-skip` is not unintentionally overriding a desired `--packages-select` target.
Always quote your package patterns (e.g., `colcon build --packages-select 'my_pkg*'` or use colcon's `--regex` option if available for more complex patterns. Consult `colcon`'s documentation for specific pattern matching capabilities.