Skip to content

Commit

Permalink
Test automatic release creation
Browse files Browse the repository at this point in the history
  • Loading branch information
kokolihapihvi committed Oct 7, 2023
1 parent fcb0478 commit 5c484a4
Showing 1 changed file with 28 additions and 3 deletions.
31 changes: 28 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
on: [push, pull_request]
on: [ push ]

jobs:
build:
Expand Down Expand Up @@ -27,7 +27,32 @@ jobs:
dotnet publish RockSniffer -c Release -o ./publish --runtime win-x64 --framework=net6.0-windows --self-contained false -p:PublishSingleFile=true
cp -r ./addons ./publish/addons
(cd ./publish && zip -r "$OLDPWD/RockSniffer $SNIFFER_VERSION.zip" .)
echo "$SNIFFER_VERSION" > VERSION
- uses: actions/upload-artifact@v3
with:
name: RockSniffer-release
path: ./RockSniffer ${{ steps.build.outputs.SNIFFER_VERSION }}.zip
name: RockSniffer-release
path: |
VERSION
./RockSniffer ${{ steps.build.outputs.SNIFFER_VERSION }}.zip
release:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/download-artifact@v3
with:
name: RockSniffer-release
- name: Get version
id: get-version
run: |
echo "SNIFFER_VERSION=$(cat VERSION)" >> "$GITHUB_OUTPUT"
- uses: ncipollo/release-action@v1
with:
name: v${{ steps.get-version.outputs.SNIFFER_VERSION }}
tag: v${{ steps.get-version.outputs.SNIFFER_VERSION }}
updateOnlyUnreleased: true
commit: ${{ github.sha }}
prerelease: true
draft: true
generateReleaseNotes: true
artifacts: "*.zip"

0 comments on commit 5c484a4

Please sign in to comment.