Skip to content

Implement release action #15

Implement release action

Implement release action #15

Workflow file for this run

name: Release
on:
workflow_dispatch:
inputs:
tag:
description: 'Tag for the release'
required: true
pull_request:
jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/[email protected]
- name: Download artifact
id: download-artifact
uses: dawidd6/action-download-artifact@v2
with:
github_token: ${{secrets.GITHUB_TOKEN}}
workflow: main.yml
workflow_conclusion: success
commit: ${{github.event.pull_request.head.sha}}
# Optional, check the workflow run to whether it has an artifact
# then will get the last available artifact from the previous workflow
# default false, just try to download from the last one
check_artifacts: true
# Optional, choose to skip unpacking the downloaded artifact(s)
# default false
skip_unpack: true
if_no_artifact_found: fail
- name: Create Release
id: create_release
uses: actions/create-release@v1
with:
tag_name: ${{ github.event.inputs.tag }}
release_name: Release ${{ github.event.inputs.tag }}
draft: false
prerelease: false
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: List files
run: ls -al
- name: Upload Release Asset 4.24
uses: actions/upload-release-asset@v1
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: UnrealLibretro-4.24.zip
asset_name: UnrealLibretro-4.24.zip
asset_content_type: application/zip
# Repeat the above step for other versions 4.25, 4.26, and so on...