Skip to content

Commit

Permalink
Release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
29cmb committed Jul 29, 2024
1 parent ed71f52 commit 0d10a6d
Showing 1 changed file with 55 additions and 0 deletions.
55 changes: 55 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: Manual Release

on:
workflow_dispatch:
inputs:
version:
description: 'Version number for the release'
required: true
default: '1.0.0'

jobs:
build-and-release:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Run workflow to build
uses: convictional/trigger-workflow-and-wait@v1.6.1
with:
owner: ${{ github.repository_owner }}
repo: ${{ github.event.repository.name }}
github_token: ${{ secrets.GITHUB_TOKEN }}
workflow_file_name: build-love-file.yml
wait_interval: 10
trigger_workflow: true
wait_workflow: true

- name: Download artifact
uses: actions/download-artifact@v3
with:
name: Game Build
path: ./release-artifacts

- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: v${{ github.event.inputs.version }}
release_name: Release ${{ github.event.inputs.version }}
draft: false
prerelease: false

- name: Upload Release Asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./release-artifacts/Game Build.zip
asset_name: GameBuild-${{ github.event.inputs.version }}.zip
asset_content_type: application/zip

0 comments on commit 0d10a6d

Please sign in to comment.