Skip to content

Commit

Permalink
Migrated to unified build script
Browse files Browse the repository at this point in the history
  • Loading branch information
Johann Bernhardt committed Dec 12, 2021
1 parent 311ab89 commit 20b5d29
Show file tree
Hide file tree
Showing 33 changed files with 844 additions and 568 deletions.
65 changes: 0 additions & 65 deletions .circleci/config.yml

This file was deleted.

17 changes: 0 additions & 17 deletions .gitattributes

This file was deleted.

9 changes: 9 additions & 0 deletions .github/scripts/test-no-crash-reports.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
directory="run/crash-reports"
if [ -d $directory ]; then
echo "Crash reports detected:"
cat $directory/*
exit 1
else
echo "No crash reports detected"
exit 0
fi
45 changes: 45 additions & 0 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle

name: Build and test

on:
pull_request:
branches: [ master, main ]
push:
branches: [ master, main ]

jobs:
build-and-test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Set up JDK 8
uses: actions/setup-java@v2
with:
java-version: '8'
distribution: 'adopt'
cache: gradle

- name: Grant execute permission for gradlew
run: chmod +x gradlew

- name: Setup the workspace
run: ./gradlew setupCIWorkspace

- name: Build the mod
run: ./gradlew build

- name: Run server for 1 minute
run: |
mkdir run
echo "eula=true" > run/eula.txt
timeout 60 ./gradlew runServer || true
- name: Test no crashes happend
run: |
chmod +x .github/scripts/test-no-crash-reports.sh
.github/scripts/test-no-crash-reports.sh
45 changes: 45 additions & 0 deletions .github/workflows/release-tags.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle

name: Release tagged build

on:
push:
tags:
- '*'

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Set release version
run: echo "RELEASE_VERSION=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV

- name: Set up JDK 8
uses: actions/setup-java@v2
with:
java-version: '8'
distribution: 'adopt'
cache: gradle

- name: Grant execute permission for gradlew
run: chmod +x gradlew

- name: Setup the workspace
run: ./gradlew setupCIWorkspace

- name: Build the mod
run: ./gradlew build

- name: Release under current tag
uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
automatic_release_tag: "${{ env.RELEASE_VERSION }}"
prerelease: false
title: "${{ env.RELEASE_VERSION }}"
files: build/libs/*.jar
169 changes: 24 additions & 145 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,149 +1,28 @@
# Windows image file caches
Thumbs.db
ehthumbs.db

# Folder config file
Desktop.ini

# Recycle Bin used on file shares
$RECYCLE.BIN/

# Windows Installer files
*.cab
*.log
*.log.gz
*.msi
*.msm
*.msp
*.json
*.txt
*.zip

# Windows shortcuts
*.lnk

# =========================
# Operating System Files
# =========================

# OSX
# =========================

.DS_Store
.AppleDouble
.LSOverride

# Thumbnails
._*

# Files that might appear in the root of a volume
.DocumentRevisions-V100
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.VolumeIcon.icns

# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk

# Created by https://www.gitignore.io/api/eclipse

### Eclipse ###

.metadata
tmp/
*.tmp
*.bak
*.swp
*~.nib
local.properties
.settings/
.loadpath

# Eclipse Core
.project

# External tool builders
.externalToolBuilders/

# Locally stored "Eclipse launch configurations"
*.launch

# PyDev specific (Python IDE for Eclipse)
*.pydevproject

# CDT-specific (C/C++ Development Tooling)
.cproject

# JDT-specific (Eclipse Java Development Tools)
.gradle
.settings
/.idea/
/run/
/build/
/eclipse/
.classpath

# Java annotation processor (APT)
.factorypath

# PDT-specific (PHP Development Tools)
.buildpath

# sbteclipse plugin
.target

# TeXlipse plugin
.texlipse

# STS (Spring Tool Suite)
.springBeans

# IDEA
.idea/
.project
/bin/
/config/
/crash-reports/
/logs/
options.txt
/saves/
usernamecache.json
banned-ips.json
banned-players.json
eula.txt
ops.json
server.properties
servers.dat
usercache.json
whitelist.json
/out/
*.iml
*.ipr
*.iws

# Other
backups
bin
blueprints
build
config
crash-reports
gradle
local
logs
modpack
mods
resourcepacks
saves
screenshots
scripts
.circleci
.gradle
.okhttpcache
/src/Java/gtPlusPlus/preloader/asm/visitors/ob/sprinkler/Visitor_Field_Sprinkler.java
/src/Java/gtPlusPlus/preloader/asm/visitors/ob/sprinkler/Visitor_Method_Sprinkler_GetInventory.java
/src/Java/gtPlusPlus/preloader/asm/visitors/ob/sprinkler/Visitor_Method_Sprinkler_UpdateEntity.java
/src/Java/gtPlusPlus/xmod/galacticraft/asm/EntityAutoRocket_ASM.java
/src/Java/gtPlusPlus/xmod/galacticraft/asm/FluidUtil_ASM.java
/src/Java/gtPlusPlus/xmod/galacticraft/asm/TileEntityFuelLoader_ASM.java
/src/Java/gtPlusPlus/xmod/ob/TileEntitySprinkler_ASM.java
/src/Java/gtPlusPlus/xmod/thermalfoundation/asm/OreDictionaryArbiter_ASM.java
/GeneratedIcons
/unused libs
/world
/server.properties
/servers.dat
/GregTech.cfg
/GregTech.lang
/GTPP.dat
/PlayerCache.dat
wip
*.bat
GT++.ipr
GT++.iws


out
src/main/resources/mixins.*.json
1 change: 0 additions & 1 deletion .gradle/2.0/taskArtifacts/cache.properties

This file was deleted.

Binary file removed .gradle/2.0/taskArtifacts/cache.properties.lock
Binary file not shown.
Binary file removed .gradle/2.0/taskArtifacts/fileHashes.bin
Binary file not shown.
Binary file removed .gradle/2.0/taskArtifacts/fileSnapshots.bin
Binary file not shown.
Binary file removed .gradle/2.0/taskArtifacts/outputFileStates.bin
Binary file not shown.
Binary file removed .gradle/2.0/taskArtifacts/taskArtifacts.bin
Binary file not shown.
23 changes: 0 additions & 23 deletions .project

This file was deleted.

1 change: 0 additions & 1 deletion Recommended.txt

This file was deleted.

2 changes: 0 additions & 2 deletions SupporterList.txt

This file was deleted.

1 change: 0 additions & 1 deletion _config.yml

This file was deleted.

3 changes: 3 additions & 0 deletions addon.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
compileJava {
options.encoding = "UTF-8"
}
Loading

0 comments on commit 20b5d29

Please sign in to comment.