Skip to content

Commit

Permalink
pass vars
Browse files Browse the repository at this point in the history
  • Loading branch information
turikhay committed Mar 23, 2024
1 parent de75940 commit 73331f0
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 8 deletions.
10 changes: 10 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ on:
type: string
spigot-target:
type: string
hangar-upload:
type: boolean
modrinth-upload:
type: boolean
outputs:
artifact:
description: Path to the jar artifact
Expand All @@ -16,6 +20,12 @@ on:
permissions:
contents: write

env:
HANGAR_UPLOAD: ${{ inputs.hangar-upload }}
HANGAR_TOKEN: ${{ secrets.HANGAR_TOKEN }}
MODRINTH_UPLOAD: ${{ inputs.modrinth-upload }}
MODRINTH_TOKEN: ${{ secrets.MODRINTH_TOKEN }}

jobs:
build:
name: Gradle build
Expand Down
5 changes: 1 addition & 4 deletions .github/workflows/hangar.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@ name: Hangar release

on: workflow_dispatch

env:
HANGAR_UPLOAD: true
HANGAR_TOKEN: ${{ secrets.HANGAR_TOKEN }}

jobs:
version:
name: Detect version
Expand All @@ -16,3 +12,4 @@ jobs:
uses: ./.github/workflows/build.yml
with:
version: ${{ needs.version.outputs.version }}
hangar-upload: true
5 changes: 1 addition & 4 deletions .github/workflows/modrinth.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@ name: Modrinth release

on: workflow_dispatch

env:
MODRINTH_UPLOAD: true
MODRINTH_TOKEN: ${{ secrets.MODRINTH_TOKEN }}

jobs:
version:
name: Detect version
Expand All @@ -16,3 +12,4 @@ jobs:
uses: ./.github/workflows/build.yml
with:
version: ${{ needs.version.outputs.version }}
modrinth-upload: true

0 comments on commit 73331f0

Please sign in to comment.