ros2cli
ros2cli copied to clipboard
[ros2pkg] Integrate features of 3rd-party ros2-pkg-create CLI tool
We have recently open-sourced our own package generation tool ros2-pkg-create
. Please also see my introductory post on ROS Discourse.
I'm opening this draft PR in response to @tfoote suggesting to integrate ros2-pkg-create
s features into the official CLI.
[!NOTE] This PR is not carrying any changes just yet. I'm mainly opening this to share some insights into the features of
ros2-pkg-create
, how it's different than this repository'sros2 pkg create
, and how an integration here could look like. Ideally, we could gather some feedback and suggestions before starting the actual integration efforts.
Features of ros2-pkg-create
- templates for three types of packages
- C++ Package
- Python Package
- Interfaces Package (msg, srv, action)
- support for basic and advanced features for both C++ and Python
- publisher
- subscriber
- parameter loading
- launch file (py/xml/yml)
- service server
- action server
- timer callback
- C++ component
- C++ lifecycle
- docker-ros
- interactive CLI questionnaire for options not specified as CLI arguments
Technical Details of ros2-pkg-create
- CLI implemented in Python
- interactive questionnaire based on copier
- templates based on jinja templating engine, see example header
- installable via pip
Differences between ros2-pkg-create
and ros2 pkg create
-
ros2 pkg create
uses empy instead of jinja, see example header -
ros2 pkg create
-only features:- setting dependencies via CLI arg
- choosing C++ node vs library
- choosing cmake vs ament_cmake build types
-
ros2-pkg-create
-only features:- interactive questionnaire for options not via CLI arg; can also use defaults, though
- generation of more than a barebones C++/Python node, see list of features above (e.g., publisher, launch file, action server, etc.)
- generation of an interfaces package