Skip to content

Commit

Permalink
Update to 1.21.1 (#38)
Browse files Browse the repository at this point in the history
  • Loading branch information
Hugman76 authored Jan 23, 2025
2 parents a06fbf2 + 557cea0 commit f3eaa61
Show file tree
Hide file tree
Showing 487 changed files with 983 additions and 7,776 deletions.
11 changes: 9 additions & 2 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,2 +1,9 @@
# Auto detect text files and perform LF normalization
* text=auto
#
# https://help.github.com/articles/dealing-with-line-endings/
#
# Linux start script should use lf
/gradlew text eol=lf

# These are Windows script files and should use crlf
*.bat text eol=crlf

41 changes: 24 additions & 17 deletions .github/workflows/check_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,35 +5,42 @@

name: Check Build
on:
pull_request:
types: [review_requested, ready_for_review]
push:
branches: [main, dev]
branches: [ main, dev ]
pull_request:
branches:
- main
- dev
types: [ opened, synchronize, reopened, ready_for_review ]

jobs:
build:
if: github.event.pull_request.draft == false
strategy:
matrix:
java: [ 17 ]
java: [ 21 ]
os: [ ubuntu-20.04 ]
name: Build the project (Java ${{ matrix.java }}, on ${{ matrix.os }}))
runs-on: ${{ matrix.os }}
steps:

- name: Checkout repository
uses: actions/checkout@v2
- name: Checkout repository
uses: actions/checkout@v2

- name: Validate Gradle wrapper
uses: gradle/wrapper-validation-action@v1

- name: Validate Gradle wrapper
uses: gradle/wrapper-validation-action@v1
- name: Setup JDK ${{ matrix.java }}
uses: actions/setup-java@v1
with:
java-version: ${{ matrix.java }}

- name: Setup JDK ${{ matrix.java }}
uses: actions/setup-java@v1
with:
java-version: ${{ matrix.java }}
- name: Make Gradle wrapper executable
if: ${{ runner.os != 'Windows' }}
run: chmod +x ./gradlew

- name: Make Gradle wrapper executable
if: ${{ runner.os != 'Windows' }}
run: chmod +x ./gradlew
- name: Generate data files
run: ./gradlew runDatagen

- name: Build
run: ./gradlew build
- name: Build
run: ./gradlew build
9 changes: 6 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,16 +27,19 @@ jobs:
env:
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_PERSONAL_TOKEN }}

- name: Set up JDK 17
- name: Set up JDK 21
uses: actions/setup-java@v1
with:
java-version: '17'
java-version: '21'

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

- name: Generate data files
run: ./gradlew clean runDatagen

- name: Build with Gradle
run: ./gradlew clean build -Pversion=${{ github.event.release.tag_name }}
run: ./gradlew build -Pversion=${{ github.event.release.tag_name }}

- name: Read Gradle properties
id: gradle_properties
Expand Down
18 changes: 16 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,13 @@

.gradle/
build/
logs/
out/
classes/

# eclipse

*.launch

# idea

.idea/
Expand All @@ -21,7 +24,18 @@ bin/
.classpath
.project

# macos

*.DS_Store

# fabric

run/
*.launch
src/main/generated/

# java

hs_err_*.log
replay_*.log
*.hprof
*.jfr
70 changes: 61 additions & 9 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,19 +1,71 @@
plugins {
id 'fabric-loom' version '1.2-SNAPSHOT'
id 'fabric-loom' version '1.9+'
id 'maven-publish'
}

apply from: 'https://dawnteammc.github.io/resources/gradle_scripts/fabric-mod/java-17.gradle'
group = "com.github.hugman"

repositories {
maven { url 'https://jitpack.io' } // Required for Dawn API

maven { url 'https://maven.terraformersmc.com/' } // Required for Mod Menu and Terraform APIs
maven { url 'https://maven.shedaniel.me/' } // Required for Cloth Config
maven { url 'https://maven.ryanliptak.com/' } // Required for AppleSkin
base {
archivesName = project.mod_id
}

dependencies {
modApi "com.github.DawnTeamMC:DawnAPI:${dawn_version}"
minecraft "com.mojang:minecraft:${project.minecraft_version}"
mappings "net.fabricmc:yarn:${project.yarn_mappings}:v2"
modImplementation "net.fabricmc:fabric-loader:${project.loader_version}"

modImplementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_version}"

compileOnly "com.google.code.findbugs:jsr305:3.0.2"
}

loom {
splitEnvironmentSourceSets()

mods {
"universal_ores" {
sourceSet sourceSets.main
sourceSet sourceSets.client
}
}

}

fabricApi {
configureDataGeneration {
modId = "universal_ores-datagen"
createSourceSet = true
client = true
}
}

processResources {
inputs.property "version", project.version

filesMatching("fabric.mod.json") {
expand "version": project.version
}
}

tasks.withType(JavaCompile).configureEach {
it.options.encoding = "UTF-8"
it.options.release = 21
}

java {
withSourcesJar()

sourceCompatibility = JavaVersion.VERSION_21
targetCompatibility = JavaVersion.VERSION_21
}

jar {
from("LICENSE") {
rename { "${it}_${project.base.archivesName.get()}"}
}
}

// for JitPack
configurations.configureEach {
resolutionStrategy.cacheChangingModulesFor 0, 'seconds'
}
10 changes: 4 additions & 6 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,7 @@ loader_name=Fabric
loader_icon=https://fabricmc.net/assets/logo.png

# check these on https://fabricmc.net/develop/
minecraft_version=1.20.1
yarn_mappings=1.20.1+build.8
loader_version=0.14.21
fabric_version=0.84.0+1.20.1
# https://github.com/DawnTeamMC/DawnAPI
dawn_version=5.0.0
minecraft_version=1.21.1
yarn_mappings=1.21.1+build.3
loader_version=0.16.10
fabric_version=0.115.0+1.21.1
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.11-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
Loading

0 comments on commit f3eaa61

Please sign in to comment.