Skip to content

Commit

Permalink
PreRelease 3.4.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Chikage0o0 authored Sep 9, 2022
1 parent e44e014 commit 0bdbab9
Showing 1 changed file with 30 additions and 2 deletions.
32 changes: 30 additions & 2 deletions .github/workflows/AutoBuildPack.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ on:
push:
branches: [ main ]

env:
PROJECT_ID: Cc9a9YwB
RELEASE_TYPE: 22.03-SNAPSHOT
USE_TG: true

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
Expand All @@ -26,25 +31,48 @@ jobs:
with:
go-version: '1.19'

- name: get version
id: pack_version
- name: get info
run: |
echo "pack_version=$(git show -s --format=%B | head -1 | grep -o '[0-9\.]*$')" >> $GITHUB_ENV
echo "game_version=$(grep -oP '(?<=minecraft = \")[0-9.]+' ./pack.toml)" >> $GITHUB_ENV
echo "loader=$(grep -oP '(quilt|fabric|forge)' ./pack.toml)" >> $GITHUB_ENV
# Runs a single command using the runners shell
- name: build modpack
run: bash build.sh

- name: Create changelog text
id: changelog
uses: loopwerk/tag-changelog@v1
with:
token: ${{ secrets.SECRET }}
exclude_types: other

- name: release
uses: ncipollo/release-action@v1
with:
name: ${{ env.pack_version }}
body: ${{ steps.changelog.outputs.changes }}
allowUpdates: true
tag: ${{ env.pack_version }}
commit: main
replacesArtifacts: true
token: ${{ secrets.SECRET }}
artifacts: ./*.mrpack

- name: Upload to Modrinth
uses: RubixDev/modrinth-upload@v1
with:
token: ${{ secrets.MODRINTH }}
file_path: ./*.mrpack
name: ${{ env.pack_version }}
version: ${{ env.pack_version }}
changelog: ${{ steps.changelog.outputs.changes }}
game_versions: ${{ env.game_version }}
release_type: ${{ env.RELEASE_TYPE }}
loaders: ${{ env.loader }}
featured: false
project_id: ${{ env.PROJECT_ID }}

preRelease:
runs-on: ubuntu-latest
Expand Down

0 comments on commit 0bdbab9

Please sign in to comment.