Skip to content

Commit

Permalink
Adjust github publish workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
TSRBerry committed May 21, 2023
1 parent 7d6a5ed commit 5ad3c12
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,18 @@ name: Publish release artifacts

on:
workflow_dispatch:
inputs:
tag:
description: Release git tag
type: string
required: true
push:
tags:
- '*'

permissions:
contents: write

jobs:
build_and_publish:
runs-on: ubuntu-latest
Expand All @@ -25,10 +33,21 @@ jobs:
with:
gradle-version: 7.5
arguments: -PGHIDRA_INSTALL_DIR=${{ env.GHIDRA_INSTALL_DIR }}

- uses: svenstaro/upload-release-action@v2
if: github.event_name == 'push'
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: dist/SwitchLoader-*.zip
tag: ${{ github.ref }}
overwrite: true
file_glob: true

- uses: svenstaro/upload-release-action@v2
if: github.event_name == 'workflow_dispatch'
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: dist/SwitchLoader-*.zip
tag: ${{ inputs.tag }}
overwrite: true
file_glob: true

0 comments on commit 5ad3c12

Please sign in to comment.