Add action for releases
Some checks failed
Unreal Engine Build / macos-build (push) Failing after 5s

This commit is contained in:
Goran Lazarevski 2025-03-28 12:23:40 +01:00
parent 26350c197e
commit 27c6282a5b
2 changed files with 60 additions and 0 deletions

View File

@ -0,0 +1,48 @@
name: Create Release
on:
workflow_dispatch:
inputs:
build_id:
description: 'Build Run ID to use artifacts from'
required: true
default: ''
version:
description: 'Version for this release (e.g. 1.0.0)'
required: true
default: ''
prerelease:
description: 'Is this a pre-release?'
required: true
default: 'false'
type: boolean
jobs:
create-release:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Download artifact from previous run
uses: actions/download-artifact@v3
with:
name: macos-build
path: Builds/
run-id: ${{ github.event.inputs.build_id }}
- name: List downloaded artifacts
run: |
echo "Downloaded artifacts:"
ls -la Builds/
- name: Create Release
uses: ncipollo/release-action@v1
with:
artifacts: "Builds/*"
token: ${{ secrets.GITHUB_TOKEN }}
generateReleaseNotes: true
tag: v${{ github.event.inputs.version }}
name: Release v${{ github.event.inputs.version }}
prerelease: ${{ github.event.inputs.prerelease }}
draft: false

View File

@ -81,3 +81,15 @@ jobs:
name: macos-build
path: Builds/
retention-days: 7
- name: Create Release
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/develop'
uses: ncipollo/release-action@v1
with:
artifacts: "Builds/*"
token: ${{ secrets.GITHUB_TOKEN }}
generateReleaseNotes: true
tag: v${{ github.run_number }}
name: Release v${{ github.run_number }}
prerelease: ${{ github.ref != 'refs/heads/main' }}
draft: false