Skip to content

publish

publish #7

Workflow file for this run

name: publish
on:
workflow_dispatch:
inputs:
version:
description: 'Mod version (without character v)'
required: true
type: string
release_type:
description: 'alpha, beta or release'
required: true
type: string
debug:
description: 'show details for debug'
required: true
default: true
type: boolean
jobs:
build:
uses: ./.github/workflows/build.yml
publish:
needs:
- build
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: checkout repository
uses: actions/checkout@v3.5.3
- name: download build artifacts
uses: actions/download-artifact@v3
with:
name: artifacts
path: artifacts
- name: sort artifacts by game version
run: |
bash ./.github/scripts/sort_artifacts.sh
- name: show details for debug
if: ${{ inputs.debug == true }}
run: |
apt install tree -y
echo @@@@@###########################################@@@@@
echo @@@@@###########################################@@@@@
echo #### Mod version: ${{ inputs.version }}
echo #### Release type: ${{ inputs.release_type }}
echo #### Modrinth project id: SB7oe4aB
echo #### Curseforge project id: 891699
echo #### Downloaded artifacts:
ls artifacts
echo #### Processed artifacts:
tree processed_artifacts
echo @@@@@###########################################@@@@@
echo @@@@@###########################################@@@@@
continue-on-error: true
- name: Publish Minecraft Mods 1.17
uses: Kir-Antipov/mc-publish@v3.3
with:
modrinth-id: SB7oe4aB
modrinth-token: ${{ secrets.MODRINTH_TOKEN }}
curseforge-id: 891699
curseforge-token: ${{ secrets.CURSEFORGE_TOKEN }}
files: processed_artifacts/1.17.1/*.jar
name: v${{ inputs.version }} For Minecraft 1.17
version: v${{ inputs.version }}
version-type: ${{ inputs.release_type }}
loaders: fabric
game-versions: '1.17.1'
game-version-filter: any
dependencies: |-
carpet(required)
fabric-api(required)
modrinth-changelog: 'Got full change logs in [GitHub](https://github.com/OptiJava/OptCarpetAddition/releases).'
curseforge-changelog: 'Got full change logs in [GitHub](https://github.com/OptiJava/OptCarpetAddition/releases).'
retry-attempts: 3
retry-delay: 10000
- name: Publish Minecraft Mods 1.18
uses: Kir-Antipov/mc-publish@v3.3
with:
modrinth-id: SB7oe4aB
modrinth-token: ${{ secrets.MODRINTH_TOKEN }}
curseforge-id: 891699
curseforge-token: ${{ secrets.CURSEFORGE_TOKEN }}
files: processed_artifacts/1.18.2/*.jar
name: v${{ inputs.version }} For Minecraft 1.18
version: v${{ inputs.version }}
version-type: ${{ inputs.release_type }}
loaders: fabric
game-versions: '1.18.2'
game-version-filter: any
dependencies: |-
carpet(required)
fabric-api(required)
modrinth-changelog: 'Got full change logs in [GitHub](https://github.com/OptiJava/OptCarpetAddition/releases).'
curseforge-changelog: 'Got full change logs in [GitHub](https://github.com/OptiJava/OptCarpetAddition/releases).'
retry-attempts: 3
retry-delay: 10000
- name: Publish Minecraft Mods 1.19.3
uses: Kir-Antipov/mc-publish@v3.3
with:
modrinth-id: SB7oe4aB
modrinth-token: ${{ secrets.MODRINTH_TOKEN }}
curseforge-id: 891699
curseforge-token: ${{ secrets.CURSEFORGE_TOKEN }}
files: processed_artifacts/1.19.3/*.jar
name: v${{ inputs.version }} For Minecraft 1.19.3
version: v${{ inputs.version }}
version-type: ${{ inputs.release_type }}
loaders: fabric
game-versions: '1.19.3'
game-version-filter: any
dependencies: |-
carpet(required)
fabric-api(required)
modrinth-changelog: 'Got full change logs in [GitHub](https://github.com/OptiJava/OptCarpetAddition/releases).'
curseforge-changelog: 'Got full change logs in [GitHub](https://github.com/OptiJava/OptCarpetAddition/releases).'
retry-attempts: 3
retry-delay: 10000
- name: Publish Minecraft Mods 1.20.1
uses: Kir-Antipov/mc-publish@v3.3
with:
modrinth-id: SB7oe4aB
modrinth-token: ${{ secrets.MODRINTH_TOKEN }}
curseforge-id: 891699
curseforge-token: ${{ secrets.CURSEFORGE_TOKEN }}
files: processed_artifacts/1.20.1/*.jar
name: v${{ inputs.version }} For Minecraft 1.20.1
version: v${{ inputs.version }}
version-type: ${{ inputs.release_type }}
loaders: fabric
game-versions: '1.20.1'
game-version-filter: any
dependencies: |-
carpet(required)
fabric-api(required)
modrinth-changelog: 'Got full change logs in [GitHub](https://github.com/OptiJava/OptCarpetAddition/releases).'
curseforge-changelog: 'Got full change logs in [GitHub](https://github.com/OptiJava/OptCarpetAddition/releases).'
retry-attempts: 3
retry-delay: 10000
- name: Publish Minecraft Mods 1.20.4
uses: Kir-Antipov/mc-publish@v3.3
with:
modrinth-id: SB7oe4aB
modrinth-token: ${{ secrets.MODRINTH_TOKEN }}
curseforge-id: 891699
curseforge-token: ${{ secrets.CURSEFORGE_TOKEN }}
files: processed_artifacts/1.20.4/*.jar
name: v${{ inputs.version }} For Minecraft 1.20.4
version: v${{ inputs.version }}
version-type: ${{ inputs.release_type }}
loaders: fabric
game-versions: '1.20.4'
game-version-filter: any
dependencies: |-
carpet(required)
fabric-api(required)
modrinth-changelog: 'Got full change logs in [GitHub](https://github.com/OptiJava/OptCarpetAddition/releases).'
curseforge-changelog: 'Got full change logs in [GitHub](https://github.com/OptiJava/OptCarpetAddition/releases).'
retry-attempts: 3
retry-delay: 10000