Skip to content

Commit

Permalink
Create changelog and release automatically
Browse files Browse the repository at this point in the history
  • Loading branch information
ostefano committed Aug 24, 2024
1 parent 7bf3a9f commit c911597
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 4,602 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/release-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,41 @@ on:

jobs:

relase:
runs-on: ubuntu-latest
steps:

- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Get previous tag
id: previousTag
run: |
name=$(git --no-pager tag --sort=creatordate --merged ${{ github.ref_name }} | tail -2 | head -1)
echo "previousTag: $name"
echo "previousTag=$name" >> $GITHUB_ENV
- name: Update changelog
id: changelog
uses: requarks/changelog-action@v1
with:
token: ${{ github.token }}
fromTag: ${{ github.ref_name }}
toTag: ${{ env.previousTag }}
writeToFile: false

- name: Create release
uses: ncipollo/release-action@v1.12.0
with:
allowUpdates: true
draft: false
makeLatest: true
name: ${{ github.ref_name }}
body: ${{ steps.changelog.outputs.changes }}
token: ${{ secrets.GITHUB_TOKEN }}

docs:
runs-on: ubuntu-latest
steps:
Expand Down
Loading

0 comments on commit c911597

Please sign in to comment.