Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding bits for first release #7

Merged
merged 5 commits into from
Jun 25, 2021
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 26 additions & 2 deletions massrobotics_amr_sender_py/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ git clone https://github.com/inorbit-ai/ros_amr_interop.git ./src
colcon build --packages-select massrobotics_amr_sender
```

## Running the node
## Running the node from source

The node takes the Mass AMR config file path as parameter. If not provided, it is assumed the file is on the current directory.
The node takes the MassRobotics AMR config file path as parameter. If not provided, it is assumed the file is on the current directory.

```bash
# Source the local overlay by running `. install/setup.sh` if
Expand All @@ -33,3 +33,27 @@ On you local workspace:
colcon test --packages-select massrobotics_amr_sender
colcon test-result --verbose
```

## Releasing a new version
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My bad memory tells me this is something done by the maintainers, so it's not very useful to mix with usage documentation. It should probably go elsewhere.
Could you do me a favor and check other packages to see if it's common to include the release instructions in the package README?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TBH most of the packages I've seen don't have a README, but I agree that this shouldn't be here. Actually, these are notes I took while testing commands

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps a separate file, like MAINTAINER_README.md ? I agree the instructions shouldn't be in the README, but I wouldn't just throw them away since they are useful indeed


This is a summary of the steps required for releasing a new package.

1. Run ``catkin_generate_changelog`` to generate or update CHANGELOG.rst file(s)

```bash
# Change directory to repository root folder
$ cd ../
$ catkin_generate_changelog
Found packages: massrobotics_amr_sender
Querying commit information since latest tag...
Updating forthcoming section of changelog files...
- updating 'massrobotics_amr_sender_py/CHANGELOG.rst'
Done.
Please review the extracted commit messages and consolidate the changelog entries before committing the files!
```

2. Open ``CHANGELOG.rst`` and edit to your liking. Then commit your new/updated changelog.

3. Run ``catkin_prepare_release`` for bumping up package version. By default this command increases the patch version of your package, e.g. ``0.1.1 -> 0.1.2``, but you can pick minor or major using the ``--bump`` option.

**Note**: this command increment the version in your ``package.xml``'s, and commit/tag the changes with a bloom compatible flag.
6 changes: 5 additions & 1 deletion massrobotics_amr_sender_py/setup.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
from setuptools import setup, find_packages
import xml.etree.ElementTree as ET

# Read version from ``package.xml`` file
package_xml = ET.parse('package.xml').getroot()

package_name = 'massrobotics_amr_sender'

Expand All @@ -7,7 +11,7 @@
packages=find_packages(),
package_data={'': ['schema.json']},
include_package_data=True,
version='0.0.2',
version=package_xml.find('version').text,
data_files=[
('share/ament_index/resource_index/packages',
['resource/' + package_name]),
Expand Down
8 changes: 8 additions & 0 deletions workspace.code-workspace
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"folders": [
{
"path": "massrobotics_amr_sender_py"
}
],
"settings": {}
}