Skip to content

Commit

Permalink
Add auto create release
Browse files Browse the repository at this point in the history
  • Loading branch information
bigzaja4 committed Jan 15, 2024
1 parent 7b5c303 commit a35f182
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 7 deletions.
31 changes: 31 additions & 0 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name-template: "Version $RESOLVED_VERSION"
tag-template: "tags/$RESOLVED_VERSION"
template: |
## Changes
$CHANGES
categories:
- title: "🚀 Features"
labels:
- "feature"
- title: "🐛 Bug Fixes"
labels:
- "fix"
- title: "🧰 Maintenance"
label: "chore"
- title: "Debt"
labels:
- "debt"
change-template: "- $TITLE @$AUTHOR (#$NUMBER)"
change-title-escapes: '\<*_&' # You can add # and @ to disable mentions, and add ` to disable code blocks.
version-resolver:
major:
labels:
- "major"
minor:
labels:
- "minor"
patch:
labels:
- "patch"
default: patch
21 changes: 14 additions & 7 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,24 @@ env:
ECR_REGISTRY: ${{ secrets.AWS_ECR_REGISTRY }}

jobs:
create-release:
name: Create Release
update_release_draft:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Create release
- uses: actions/checkout@v2
- name: Get Version
uses: sergeysova/jq-action@v2
id: version
with:
cmd: 'jq .version package.json -r'
- name: Prepare environment variable for release-drafter
run: echo 'VERSION=${{ steps.version.outputs.value }}' >> $GITHUB_ENV
- uses: release-drafter/release-drafter@v5
with:
config-name: release-drafter.yml
version: ${{ env.VERSION }}
publish: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: gh release create "$GITHUB_REF_NAME" --notes "Directus $GITHUB_REF_NAME"

build-images:
name: Build Images
Expand Down

0 comments on commit a35f182

Please sign in to comment.