Skip to content

Commit

Permalink
fix pre-release
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisTitusTech committed Aug 30, 2024
1 parent d315963 commit 2d3dbe4
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 6 deletions.
5 changes: 3 additions & 2 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name-template: 'v$RESOLVED_VERSION'
tag-template: 'v$RESOLVED_VERSION'
name-template: '$RESOLVED_VERSION'
tag-template: '$RESOLVED_VERSION'
tag-prefix: ""
categories:
- title: '🚀 Features'
labels:
Expand Down
18 changes: 14 additions & 4 deletions .github/workflows/pre-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,13 @@ jobs:
name: winutil
path: ./winutil.ps1

- name: Get latest release tag
id: get_latest_release
run: |
$latestTag = git describe --tags --abbrev=0
echo "LATEST_TAG=$latestTag" >> $env:GITHUB_ENV
shell: pwsh

- name: Generate Release Notes
id: generate_notes
uses: release-drafter/release-drafter@v5
Expand All @@ -82,14 +89,17 @@ jobs:
with:
config-name: release-drafter.yml
version: ${{ env.version }}
tag: ${{ env.LATEST_TAG }}

- name: Prepare Release Body
id: prepare_body
run: |
new_changes="${{ steps.generate_notes.outputs.body }}"
echo "body<<EOF" >> $GITHUB_OUTPUT
echo "$new_changes" >> $GITHUB_OUTPUT
echo "EOF" >> $GITHUB_OUTPUT
$newChanges = "${{ steps.generate_notes.outputs.body }}"
$formattedChanges = "Changes since ${{ env.LATEST_TAG }}:`n`n$newChanges"
echo "body<<EOF" >> $env:GITHUB_OUTPUT
echo "$formattedChanges" >> $env:GITHUB_OUTPUT
echo "EOF" >> $env:GITHUB_OUTPUT
shell: pwsh

- name: Create and Upload Release
id: create_release
Expand Down

0 comments on commit 2d3dbe4

Please sign in to comment.