Skip to content

Commit

Permalink
Create releases automatically when VERSION is updated (contiv#4)
Browse files Browse the repository at this point in the history
Signed-off-by: Antonin Bas <[email protected]>
  • Loading branch information
antoninbas authored Jul 6, 2021
1 parent bdd82da commit dbd1b5d
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 0 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Release
on:
push:
branches:
- main
paths:
- 'VERSION'

jobs:
release:
runs-on: [ubuntu-latest]
steps:
- name: Check-out code
uses: actions/checkout@v2
- name: Read version
run: |
echo "version=$(head VERSION)" >> $GITHUB_ENV
- name: Create release
uses: ncipollo/release-action@v1
with:
omitBody: true
token: "${{ secrets.GITHUB_TOKEN }}"
tag: "${{ env.version }}"
commit: "${{ env.GITHUB_SHA }}"
7 changes: 7 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,13 @@ Thank you for taking the time out to contribute to project Antrea!

## Contribute

### Versioning

This project follows the [semantic versioning
specification](https://semver.org/). A new Github release is created
automatically whenever a commit is pushed to the "main" branch which modifies
the `VERSION` file.

### Inclusive Naming

For symbol names and documentation, do not introduce new usage of harmful
Expand Down
1 change: 1 addition & 0 deletions VERSION
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
v0.1.0

0 comments on commit dbd1b5d

Please sign in to comment.