Initial Commit

This commit is contained in:
Sofiane H. Djerbi
2023-01-09 17:31:30 +01:00
commit 31fdec1248
15 changed files with 1454 additions and 0 deletions

25
.github/workflows/build.yml vendored Normal file
View File

@@ -0,0 +1,25 @@
name: Generate Jars
on: [ push, pull_request ]
jobs:
paperclip:
runs-on: ubuntu-latest
steps:
- name: Checkout Git Repository
uses: actions/checkout@v2
- name: Set up JDK
uses: actions/setup-java@v2.5.0
with:
java-version: '17'
cache: 'gradle'
distribution: 'temurin'
- name: Configure Git User Details
run: git config --global user.email "actions@github.com" && git config --global user.name "Github Actions"
- name: Apply Patches
run: ./gradlew applyPatches --stacktrace
- name: Build Paperclip jar
run: ./gradlew createReobfPaperclipJar --stacktrace
- name: Upload Paperclip jar
uses: actions/upload-artifact@v2
with:
name: kaiiju.jar
path: build/libs/kaiiju-paperclip-*-reobf.jar

44
.github/workflows/upstream.yml vendored Normal file
View File

@@ -0,0 +1,44 @@
name: Update Upstream
on:
schedule:
- cron: '0 15 * * *' # Once a day at 5pm GMT+2
workflow_dispatch: # on button click
jobs:
upstream:
runs-on: ubuntu-latest
steps:
- name: Checkout Git Repository
uses: actions/checkout@v2
- name: Set up JDK
uses: actions/setup-java@v2.5.0
with:
java-version: '17'
cache: 'gradle'
distribution: 'temurin'
- name: Configure Git User Details
run: git config --global user.email "actions@github.com" && git config --global user.name "Github Actions"
- name: Update Upstream Commit Hash
run: ./gradlew purpurRefLatest --stacktrace
- name: Apply Patches
run: ./gradlew applyPatches --stacktrace
- name: Build Paperclip jar
run: ./gradlew jar createReobfPaperclipJar --stacktrace
- name: Rebuild Patches
run: ./gradlew rebuildPatches --stacktrace
- name: Upload Paperclip jar
uses: actions/upload-artifact@v2
with:
name: kaiiju.jar
path: build/libs/kaiiju-paperclip-*-reobf.jar
- name: Create Pull Request
uses: peter-evans/create-pull-request@v3
with:
commit-message: Update Upstream
branch: update-upstream
delete-branch: true
title: 'Update Upstream'
body: ''