Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Mod Infra #25

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 0 additions & 20 deletions .github/workflows/build.yml

This file was deleted.

22 changes: 22 additions & 0 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Run Tests
on: [push, pull_request]
jobs:
gradle:
strategy:
matrix:
java: [17, 21]
runs-on: ubuntu-22.04
steps:
- uses: actions/setup-java@v3
with:
java-version: ${{ matrix.java }}
distribution: 'temurin'
- uses: actions/checkout@v3
- name: 'Build'
run: ./gradlew build publishMods --stacktrace --warning-mode=fail
- name: 'Upload artifacts'
if: ${{ matrix.java == '20' }}
uses: actions/upload-artifact@v3
with:
name: Artifacts
path: build/libs/
30 changes: 22 additions & 8 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,31 @@ name: Release
on: [workflow_dispatch] # Manual trigger
jobs:
build:
runs-on: ubuntu-20.04
container:
image: openjdk:17-jdk
options: --user root
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v1
- uses: gradle/wrapper-validation-action@v1
- run: chmod +x ./gradlew
- run: ./gradlew checkVersion build publish curseforge --stacktrace --warning-mode fail
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: actions/setup-java@v3
with:
java-version: 21
distribution: 'temurin'
- uses: FabricMC/fabric-action-scripts@v2
id: changelog
with:
context: changelog
workflow_id: release.yml
- run: ./gradlew build publishMods publish --stacktrace --warning-mode=fail
env:
MAVEN_URL: ${{ secrets.MAVEN_URL }}
MAVEN_USERNAME: ${{ secrets.MAVEN_USERNAME }}
MAVEN_PASSWORD: ${{ secrets.MAVEN_PASSWORD }}
CURSEFORGE_API_KEY: ${{ secrets.CURSEFORGE_API_KEY }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
MODRINTH_TOKEN: ${{ secrets.MODRINTH_TOKEN }}
CHANGELOG: ${{ steps.changelog.outputs.changelog }}
- run: ./gradlew processMDTemplates
- uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: Update readme
commit_author: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
22 changes: 22 additions & 0 deletions .github/workflows/update.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Update Check
on:
workflow_dispatch:
schedule:
- cron: "0 0 * * *"
jobs:
build:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- uses: actions/setup-java@v3
with:
java-version: 21
distribution: 'temurin'
- run: ./gradlew updateVersions
- run: ./gradlew processMDTemplates
- uses: peter-evans/create-pull-request@v4
with:
branch: update-versions
title: Update versions
author: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
commit-message: Update versions
13 changes: 11 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,26 @@

# Folders
!/gradle
!/buildSrc
!/src
!/generated

# Files
!/.gitattributes
!/.gitignore
!/build.gradle
!/settings.gradle
!/gradle.properties
!/gradlew
!/gradlew.bat
!/HEADER
!/Jenkinsfile
!/LICENSE
!/README.md
!.github
!/settings.gradle

!/sample-mod
!/templates/
!/.github/

build/
.gradle/
Loading