Skip to content

Commit

Permalink
Optimize File Size
Browse files Browse the repository at this point in the history
Co-Authored-By: Brady <[email protected]>
  • Loading branch information
AlexNijjar and ThatGravyBoat committed Jul 10, 2023
1 parent f0b01cd commit 71717ef
Show file tree
Hide file tree
Showing 12,803 changed files with 105 additions and 32 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
105 changes: 73 additions & 32 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,44 +1,85 @@
name: Release
on: [
workflow_dispatch
]

name: Publish Release
on:
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-22.04
publish-release:
runs-on: ubuntu-latest
steps:
- name: Cache Gradle packages
uses: actions/cache@v1
- name: Checkout Repository
uses: actions/checkout@v2

- name: Setup Java
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: 17

- name: Setup Gradle Caches
uses: actions/cache@v3
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }}
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }}
restore-keys: ${{ runner.os }}-gradle
- uses: actions/checkout@v2
- uses: actions/setup-java@v3

- name: Setup Gradle Wrapper
run: chmod +x gradlew

- name: Get Version and Platform
id: properties
uses: christian-draeger/[email protected]
with:
distribution: 'adopt'
java-version: '17'
- run: chmod +x ./gradlew
path: "./gradle.properties"
properties: "version enabledPlatforms minecraftVersion"

- name: Release
run: ./gradlew :fabric:modrinth :forge:modrinth :fabric:curseforge :forge:curseforge
- name: Publish Release
run: ./gradlew publish --info
env:
CURSE_TOKEN: ${{ secrets.CURSE_TOKEN }}
CURSE_PROJECT: ${{ secrets.CURSE_PROJECT }}
MODRINTH_TOKEN: ${{ secrets.MODRINTH_TOKEN }}
MODRINTH_PROJECT: ${{ secrets.MODRINTH_PROJECT }}
MAVEN_USER: ${{ secrets.MAVEN_USERNAME }}
MAVEN_PASS: ${{ secrets.MAVEN_PASSWORD }}

- run: ./gradlew generateDiscordEmbed
env:
MODRINTH_PROJECT_URL: ${{ secrets.MODRINTH_PROJECT_URL }}
CURSE_PROJECT_URL: ${{ secrets.CURSE_PROJECT_URL }}
EMBED_COLOR: ${{ secrets.EMBED_COLOR }}
WEBHOOK_THUMBNAIL: ${{ secrets.WEBHOOK_THUMBNAIL }}
WEBHOOK_USERNAME: ${{ secrets.WEBHOOK_USERNAME }}
WEBHOOK_AVATAR: ${{ secrets.WEBHOOK_AVATAR }}

- name: Trigger Discord Webhook
- name: Upload Forge Releases (Curse/Modrinth/Github)
if: contains(steps.properties.outputs.enabledPlatforms, 'forge')
uses: Kir-Antipov/[email protected]
with:
curseforge-id: ${{ vars.CURSE_ID }}
curseforge-token: ${{ secrets.CURSE_TOKEN }}

modrinth-id: ${{ vars.MODRINTH_ID }}
modrinth-token: ${{ secrets.MODRINTH_TOKEN }}

files: ./forge/build/libs/!(*-@(dev|sources|dev-shadow)).jar
name: "[Forge] Chipped ${{ steps.properties.outputs.version }}"
version: ${{ steps.properties.outputs.version }}
version-type: release
changelog-file: changelog.md
loaders: forge
game-versions: ${{ steps.properties.outputs.minecraftVersion }}
version-resolver: exact

- name: Upload Fabric Releases (Curse/Modrinth/Github)
if: contains(steps.properties.outputs.enabledPlatforms, 'fabric')
uses: Kir-Antipov/[email protected]
with:
curseforge-id: ${{ vars.CURSE_ID }}
curseforge-token: ${{ secrets.CURSE_TOKEN }}

modrinth-id: ${{ vars.MODRINTH_ID }}
modrinth-token: ${{ secrets.MODRINTH_TOKEN }}

files: ./fabric/build/libs/!(*-@(dev|sources|dev-shadow)).jar
name: "[Fabric] Chipped ${{ steps.properties.outputs.version }}"
version: ${{ steps.properties.outputs.version }}
version-type: release
changelog-file: changelog.md
loaders: forge
game-versions: ${{ steps.properties.outputs.minecraftVersion }}
version-resolver: exact

- name: Generate Discord Embed
run: ./gradlew injectEmbed

- name: Upload Discord Embed
uses: tsickert/[email protected]
with:
webhook-url: ${{ secrets.WEBHOOK_URL }}
raw-data: embed.json
raw-data: ./build/release_embed.json
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 71717ef

Please sign in to comment.