-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #60 from husarion/2.0.3-20240606
Release 2.0.3 to ros2
- Loading branch information
Showing
6 changed files
with
149 additions
and
85 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json | ||
language: "en-US" | ||
early_access: false | ||
reviews: | ||
profile: "chill" | ||
request_changes_workflow: false | ||
high_level_summary: true | ||
poem: false | ||
review_status: true | ||
collapse_walkthrough: false | ||
auto_review: | ||
enabled: true | ||
drafts: false | ||
base_branches: | ||
- "ros2-devel" | ||
chat: | ||
auto_reply: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ name: ROS2 test build | |
on: | ||
push: | ||
branches: | ||
- 'ros2' | ||
- "ros2" | ||
|
||
jobs: | ||
colcon-test-build: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
name: Validate PR head branch | ||
on: | ||
pull_request: | ||
branches: | ||
- "ros2" | ||
|
||
jobs: | ||
check-head-branch: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Check allowed branches | ||
run: | | ||
pattern="^[0-9]+\.[0-9]+\.[0-9]+-[0-9]{8}$" # This regex matches the X.X.X-YYYYMMDD pattern | ||
if [[ "${{ github.head_ref }}" == *"hotfix"* ]]; then | ||
echo "PR from a branch containing 'hotfix' is allowed." | ||
exit 0 | ||
elif [[ "${{ github.head_ref }}" =~ $pattern ]]; then | ||
echo "PR from a branch matching X.X.X-YYYYMMDD pattern is allowed." | ||
exit 0 | ||
else | ||
echo "PRs must come from branches containing 'hotfix' phrase or matching X.X.X-YYYYMMDD pattern." | ||
exit 1 | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,96 +2,115 @@ | |
name: Release repository | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
target_branch: | ||
description: Target branch for the release. | ||
required: true | ||
version: | ||
description: New version (used for tag and package versioning). | ||
required: true | ||
release_name: | ||
description: Name of the release to be created. Version in the first place is recommended (e.g. `2.0.0-alpha`). | ||
required: true | ||
automatic_mode: | ||
type: boolean | ||
default: false | ||
description: Automatically merge PR and create release. | ||
prerelease: | ||
type: boolean | ||
default: false | ||
description: Mark the release as a prerelease. | ||
workflow_dispatch: | ||
inputs: | ||
release_candidate: | ||
description: Branch name of the release candidate. | ||
required: true | ||
version: | ||
description: New version (used for tag and package versioning). | ||
required: true | ||
release_name: | ||
description: Name of the release to be created. Version in the first place is recommended (e.g. | ||
`2.0.0-alpha`). | ||
required: true | ||
automatic_mode: | ||
type: boolean | ||
default: false | ||
description: Automatically merge PR and create release. | ||
prerelease: | ||
type: boolean | ||
default: false | ||
description: Mark the release as a prerelease. | ||
|
||
jobs: | ||
release: | ||
name: Release repository | ||
runs-on: ubuntu-22.04 | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
MAIN_BRANCH: ros2 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.event.inputs.target_branch }} | ||
release: | ||
name: Release repository | ||
runs-on: ubuntu-22.04 | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
MAIN_BRANCH: ros2 | ||
DEVEL_BRANCH: ros2-devel | ||
steps: | ||
- name: Checkout to rc branch | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ github.event.inputs.release_candidate }} | ||
|
||
- name: Create release candidate | ||
id: create_release_candidate | ||
uses: at-wat/catkin-release-action@v1 | ||
with: | ||
version: ${{ github.event.inputs.version }} | ||
git_user: action-bot | ||
git_email: [email protected] | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
- name: Catkin release | ||
id: catkin_release | ||
uses: at-wat/catkin-release-action@v1 | ||
with: | ||
version: ${{ github.event.inputs.version }} | ||
git_user: action-bot | ||
git_email: [email protected] | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Create pull request | ||
run: | | ||
gh pr create \ | ||
--base ${{ github.event.inputs.target_branch }} \ | ||
--head ${{ steps.create_release_candidate.outputs.created_branch }} \ | ||
--title "Release ${{ steps.create_release_candidate.outputs.version}}" \ | ||
--body "This PR incorporates package(s) version and changelog update." | ||
- name: Catkin release - create PR | ||
run: | | ||
gh pr create \ | ||
--base ${{ github.event.inputs.release_candidate }} \ | ||
--head ${{ steps.catkin_release.outputs.created_branch }} \ | ||
--title "Release ${{ steps.catkin_release.outputs.version}}" \ | ||
--body "This PR incorporates package(s) version and changelog update." | ||
- name: Merge pull request | ||
if: ${{ fromJSON(github.event.inputs.automatic_mode) == true }} | ||
run: | | ||
gh pr merge ${{ steps.create_release_candidate.outputs.created_branch }} \ | ||
--merge --delete-branch | ||
- name: Catkin release - merge PR | ||
if: ${{ fromJSON(github.event.inputs.automatic_mode) == true }} | ||
run: | | ||
gh pr merge ${{ steps.catkin_release.outputs.created_branch }} \ | ||
--merge --delete-branch | ||
- name: Checkout to main | ||
if: ${{ github.event.inputs.target_branch != env.MAIN_BRANCH && fromJSON(github.event.inputs.automatic_mode) == true }} | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ env.MAIN_BRANCH }} | ||
- name: Checkout to main branch | ||
if: ${{ github.event.inputs.release_candidate != env.MAIN_BRANCH && fromJSON(inputs.automatic_mode) | ||
== true }} | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ env.MAIN_BRANCH }} | ||
|
||
- name: Create pull request to main | ||
if: ${{ github.event.inputs.target_branch != env.MAIN_BRANCH && fromJSON(github.event.inputs.automatic_mode) == true }} | ||
run: | | ||
gh pr create \ | ||
--base ${{ env.MAIN_BRANCH }} \ | ||
--head ${{ github.event.inputs.target_branch }} \ | ||
--title "Release ${{ steps.create_release_candidate.outputs.version}} to ${{ env.MAIN_BRANCH }}" \ | ||
--body "This PR incorporates package(s) version and changelog update." | ||
- name: Create PR to main branch | ||
if: ${{ github.event.inputs.release_candidate != env.MAIN_BRANCH && fromJSON(inputs.automatic_mode) | ||
== true }} | ||
run: | | ||
gh pr create \ | ||
--base ${{ env.MAIN_BRANCH }} \ | ||
--head ${{ github.event.inputs.release_candidate }} \ | ||
--title "Release ${{ steps.catkin_release.outputs.version}} to ${{ env.MAIN_BRANCH }}" \ | ||
--body "This PR incorporates package(s) version and changelog update." | ||
- name: Merge pull request to main | ||
if: ${{ github.event.inputs.target_branch != env.MAIN_BRANCH && fromJSON(github.event.inputs.automatic_mode) == true }} | ||
run: | | ||
gh pr merge ${{ github.event.inputs.target_branch }} \ | ||
--merge --delete-branch | ||
- name: Merge PR to main branch | ||
if: ${{ github.event.inputs.release_candidate != env.MAIN_BRANCH && fromJSON(inputs.automatic_mode) | ||
== true }} | ||
run: | | ||
gh pr merge ${{ github.event.inputs.release_candidate }} \ | ||
--merge --delete-branch | ||
- name: Create prerelease | ||
if: ${{ fromJSON(github.event.inputs.automatic_mode) == true && fromJSON(github.event.inputs.prerelease) == true}} | ||
run: | | ||
gh release create ${{ steps.create_release_candidate.outputs.version }} \ | ||
--target ${{ env.MAIN_BRANCH }} \ | ||
--title ${{ github.event.inputs.release_name }} \ | ||
--generate-notes \ | ||
--prerelease | ||
- name: Create prerelease | ||
if: ${{ fromJSON(github.event.inputs.automatic_mode) == true && fromJSON(github.event.inputs.prerelease) | ||
== true}} | ||
run: | | ||
gh release create ${{ steps.catkin_release.outputs.version }} \ | ||
--target ${{ env.MAIN_BRANCH }} \ | ||
--title ${{ github.event.inputs.release_name }} \ | ||
--generate-notes \ | ||
--prerelease | ||
- name: Create release | ||
if: ${{ fromJSON(github.event.inputs.automatic_mode) == true && fromJSON(github.event.inputs.prerelease) == false}} | ||
run: | | ||
gh release create ${{ steps.create_release_candidate.outputs.version }} \ | ||
--target ${{ env.MAIN_BRANCH }} \ | ||
--title ${{ github.event.inputs.release_name }} \ | ||
--generate-notes | ||
- name: Create release | ||
if: ${{ fromJSON(github.event.inputs.automatic_mode) == true && fromJSON(github.event.inputs.prerelease) | ||
== false}} | ||
run: | | ||
gh release create ${{ steps.catkin_release.outputs.version }} \ | ||
--target ${{ env.MAIN_BRANCH }} \ | ||
--title ${{ github.event.inputs.release_name }} \ | ||
--generate-notes | ||
- name: Checkout to devel branch | ||
if: ${{ env.DEVEL_BRANCH != env.MAIN_BRANCH && fromJSON(inputs.automatic_mode) == true }} | ||
uses: actions/checkout@v4 | ||
with: | ||
ref: ${{ env.DEVEL_BRANCH }} | ||
|
||
- name: Update devel branch | ||
if: ${{ env.DEVEL_BRANCH != env.MAIN_BRANCH && fromJSON(inputs.automatic_mode) == true }} | ||
run: | | ||
git pull origin ${{ env.MAIN_BRANCH }} | ||
git push origin ${{ env.DEVEL_BRANCH }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
<?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?> | ||
<package format="3"> | ||
<name>panther_msgs</name> | ||
<version>2.0.2</version> | ||
<version>2.0.3</version> | ||
<description>Custom messages for Panther robot.</description> | ||
<maintainer email="[email protected]">Husarion</maintainer> | ||
<license>Apache License 2.0</license> | ||
|