| 1 |
on: |
| 2 |
push: |
| 3 |
# Sequence of patterns matched against refs/tags |
| 4 |
tags: |
| 5 |
# - 'v[0-9]+.[0-9]+.[0-9]+' # Push events to matching pattern -- updated to use regex for a semantic versioning version number |
| 6 |
- 'javaparser-parent-[0-9].*' # Push events to matching pattern -- loosened pattern to be v followed by at least one number, then anything else after (this allows for e.g. "-DRAFT" and "-SNAPSHOT" as a suffix, and shorter version numbers such as "v2") |
| 7 |
|
| 8 |
name: Create Release from semantic versioning tag push |
| 9 |
|
| 10 |
jobs: |
| 11 |
build: |
| 12 |
name: Create Release |
| 13 |
runs-on: ubuntu-latest |
| 14 |
steps: |
| 15 |
- name: Checkout code |
| 16 |
uses: actions/[email protected] |
| 17 |
|
| 18 |
- name: Create Release |
| 19 |
id: create_release |
| 20 |
uses: actions/[email protected] |
| 21 |
env: |
| 22 |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, you do not need to create your own token |
| 23 |
with: |
| 24 |
tag_name: ${{ github.ref }} |
| 25 |
release_name: Release ${{ github.ref }} |
| 26 |
## Body content doesn't yet seem to appear in the Github UI |
| 27 |
# body: | |
| 28 |
# Bug Fixes: |
| 29 |
# - TODO: Describe any bug fixes |
| 30 |
# |
| 31 |
# Enhancements: |
| 32 |
# - TODO: Describe any new features or enhancements |
| 33 |
## Option -- trigger as a draft release, followed by the addition of any key release notes and manual approval? |
| 34 |
## Alternative -- replace the above body with a link to the changelog? We can always edit release after the fact to add in e.g. notes about breaking changes. |
| 35 |
draft: true |
| 36 |
prerelease: false |