Skip to content

Commit

Permalink
fix(ci): update GitHub Actions workflows
Browse files Browse the repository at this point in the history
This commit updates the GitHub Actions workflow for releases. The changes include:
- Upgrading the `actions/checkout` action to version 3
- Adding caching for Chocolatey packages
- Replacing the `actions/create-release` and `actions/upload-release-asset` actions with the `softprops/action-gh-release` action
- Updating the release step to use the `softprops/action-gh-release` action instead of the deprecated `actions/create-release` action
  • Loading branch information
dikkadev committed Aug 1, 2023
1 parent 2035cc2 commit 8767944
Showing 1 changed file with 13 additions and 21 deletions.
34 changes: 13 additions & 21 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,22 @@ on:
push:
tags:
- '*'
workflow_dispatch:

jobs:
build:
runs-on: windows-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Cache Choco packages
uses: actions/cache@v3
with:
path: ~\AppData\Local\Temp\chocolatey
key: ${{ runner.os }}-choco-${{ hashFiles('**/*.yml') }}
restore-keys: |
${{ runner.os }}-choco-
- name: Install dependencies
run: |
Expand All @@ -31,24 +40,7 @@ jobs:
cd build
make
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: false
prerelease: false

- name: Upload Release Asset
id: upload_release_asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Release
uses: softprops/action-gh-release@v1
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./build/SynthPointer.dll
asset_name: SynthPointer.dll
asset_content_type: application/octet-stream
files: ./build/SynthPointer.dll

0 comments on commit 8767944

Please sign in to comment.