Skip to content

Commit

Permalink
Update workflow to only allow releasing from pull requests
Browse files Browse the repository at this point in the history
  • Loading branch information
gonzalocasas committed Sep 11, 2024
1 parent 23a0470 commit a20e5f7
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ name: Create Release

jobs:
build:
if: github.ref == 'refs/heads/main'
runs-on: ${{ matrix.os }}
strategy:
matrix:
Expand Down
34 changes: 34 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,3 +56,37 @@ When [proposing a new feature](https://github.com/gramaziokohler/aixd_ara/issues

* Explain in detail how it would work.
* Keep the scope as narrow as possible, to make it easier to implement.

# Releasing a new version

Ready to release a new version of the project? Here's how to do it!
We follow [semantic versioning](https://semver.org) principles for our release process.
To create a new release, follow these steps:
1. Ensure all changes intended for the release are merged into the **main** branch.
2. Create a new branch from **main** to prepare the release (replace `x.y.z` with the version number you plan to release):
```bash
git checkout main
git pull
git checkout -b prepare-release-x.y.z
```
3. Ensure all checks and tests pass successfully. Use the `invoke check` and `invoke test` commands to verify.
4. Decide on the versioning increment type for the release based on the changes since the last version:
- `major` for breaking changes to the API
- `minor` for adding functionality in a backwards-compatible manner
- `patch` for backwards-compatible bug fixes
5. Run the release command with the appropriate release type:
```bash
invoke release [release_type]
```
6. Create a merge request to merge the branch into **main**. Check the changes and make sure
everything looks good, before merging.
7. Celebrate! 💃

0 comments on commit a20e5f7

Please sign in to comment.