Skip to content

Commit

Permalink
fix tags, creative tab
Browse files Browse the repository at this point in the history
  • Loading branch information
a0a7 committed Nov 13, 2023
1 parent 0e640ae commit 1d78a72
Show file tree
Hide file tree
Showing 19 changed files with 668 additions and 594 deletions.
21 changes: 0 additions & 21 deletions .editorconfig

This file was deleted.

46 changes: 40 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,40 @@
.idea
build
.gradle
run
.DS_Store
src/main/resources/assets/create
# gradle

.gradle/
build/
out/
classes/

# eclipse

*.launch

# idea

.idea/
*.iml
*.ipr
*.iws

# vscode

.settings/
.vscode/
bin/
.classpath
.project

# macos

*.DS_Store

# fabric

run/

# java

hs_err_*.log
replay_*.log
*.hprof
*.jfr
6 changes: 6 additions & 0 deletions SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Security Policy

## Reporting a Vulnerability

To report a security issue, please contact a developer with a description of the issue, the steps you took to create the
issue, affected versions, and, if known, mitigations for the issue. This project follows a 90 day disclosure timeline.
193 changes: 83 additions & 110 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,132 +1,105 @@
//file:noinspection GroovyAssignabilityCheck
plugins {
id 'dev.architectury.loom' version "${loom_version}"
id 'io.github.juuxel.loom-vineflower' version "${vineflower_version}"
id 'io.github.p03w.machete' version '2.0.1'
id 'maven-publish'
id 'fabric-loom' version '1.4-SNAPSHOT'
id 'maven-publish'
id "io.github.p03w.machete" version "1.+" // automatic jar compressing on build
}

sourceCompatibility = targetCompatibility = JavaVersion.VERSION_17

version = project.mod_version
group = project.maven_group
archivesBaseName = project.archives_base_name
String buildNumber = System.getenv("GITHUB_RUN_NUMBER")
version = "${mod_version}${ buildNumber != null ? "-${buildNumber}" : ''}+mc${minecraft_version}"

def generatedResources = file('src/generated/resources')

sourceSets.main.resources {
srcDir(generatedResources)
exclude '.cache/'
}

loom {
silentMojangMappingsLicense()

forge {
mixinConfig "interiors.mixins.json"
}

runs {
data {
data()
programArgs '--mod', 'interiors'
programArg '--all'
programArgs '--output', generatedResources.absolutePath
programArgs '--existing', file('src/main/resources/').absolutePath
programArgs '--existing-mod', 'create'
}
}
base {
archivesName = project.archives_base_name
}

repositories {
mavenCentral()
mavenLocal()
maven { url 'https://maven.parchmentmc.org' }
maven { url 'https://maven.quiltmc.org/repository/release' }
maven { url 'https://maven.blamejared.com/' }
maven { url 'https://maven.neoforged.net/releases/' }

maven {
url 'https://maven.tterrag.com/'
content {
includeGroup 'com.jozufozu.flywheel'
includeGroup 'com.tterrag.registrate'
includeGroup 'com.simibubi.create'
}
}
maven {
url 'https://api.modrinth.com/maven'
content { includeGroup 'maven.modrinth' }
}
maven {
url 'https://www.cursemaven.com'
content { includeGroup 'curse.maven' }
}
}

configurations {
jarJar

modImplementation.extendsFrom jarJar
include.extendsFrom jarJar
maven { url = "https://maven.shedaniel.me/" } // Cloth Config, REI
maven { url = "https://dvs1.progwml6.com/files/maven/" } // JEI
maven { url = "https://maven.parchmentmc.org" } // Parchment mappings
maven { url = "https://maven.quiltmc.org/repository/release" } // Quilt Mappings
maven { url = "https://api.modrinth.com/maven" } // LazyDFU
maven { url = "https://maven.terraformersmc.com/releases/" } // Mod Menu
maven { url = "https://mvn.devos.one/snapshots/" } // Create, Porting Lib, Forge Tags, Milk Lib, Registrate
maven { url = "https://cursemaven.com" } // Forge Config API Port
maven { url = "https://maven.jamieswhiteshirt.com/libs-release" } // Reach Entity Attributes
maven { url = "https://jitpack.io/" } // Mixin Extras, Fabric ASM
maven { url = "https://maven.tterrag.com/" } // Flywheel
}

dependencies {
minecraft "com.mojang:minecraft:${minecraft_version}"

mappings(loom.layered {
it.mappings("org.quiltmc:quilt-mappings:${minecraft_version}+build.${quilt_mappings}:intermediary-v2")
it.parchment("org.parchmentmc.data:parchment-${minecraft_version}:${parchment_version}@zip")
it.officialMojangMappings { nameSyntheticMembers = false }
})

forge "net.neoforged:forge:${minecraft_version}-${neo_version}"

// Create and Co.
modImplementation "com.tterrag.registrate:Registrate:${registrate_version}"
modImplementation("com.simibubi.create:create-${minecraft_version}:${create_version}:slim") { transitive = false }
modImplementation "com.jozufozu.flywheel:flywheel-forge-${minecraft_version}:${flywheel_version}"

// JEI
modCompileOnly "mezz.jei:jei-${minecraft_version}-common-api:${jei_version}"
modCompileOnly "mezz.jei:jei-${minecraft_version}-forge-api:${jei_version}"
modLocalRuntime("mezz.jei:jei-${minecraft_version}-forge:${jei_version}") { transitive = false }

// Dev QOL
modLocalRuntime 'curse.maven:better-mods-button-541584:4665757'
modLocalRuntime 'curse.maven:ferritecore-429235:4574361'
modLocalRuntime "curse.maven:catalogue-459701:4766090"
// To change the versions see the gradle.properties file
minecraft "com.mojang:minecraft:${project.minecraft_version}"
mappings(loom.layered {
it.mappings("org.quiltmc:quilt-mappings:${minecraft_version}+build.${qm_version}:intermediary-v2")
it.parchment("org.parchmentmc.data:parchment-${minecraft_version}:${parchment_version}@zip")
it.officialMojangMappings { nameSyntheticMembers = false }
})
modImplementation "net.fabricmc:fabric-loader:${project.loader_version}"

// Fabric API. This is technically optional, but you probably want it anyway.
modImplementation "net.fabricmc.fabric-api:fabric-api:${project.fabric_version}"

modImplementation("com.simibubi.create:create-fabric-${minecraft_version}:${create_version}")

// Development QOL
modLocalRuntime("maven.modrinth:lazydfu:${lazydfu_version}")
modLocalRuntime("com.terraformersmc:modmenu:${modmenu_version}")
}

processResources {
def props = [
version: mod_version,
neo_version: neo_version.split("\\.")[0], // only specify major version of forge
minecraft_version: minecraft_version,
create_version: create_version.split("-")[0] // cut off build number
]
inputs.properties props

filesMatching('META-INF/mods.toml') {
expand props
}

//don't include create's stuff in the jar in case they are there
exclude 'assets/create.zip'
exclude 'assets/create'
// require dependencies to be the version compiled against or newer
Map<String, String> properties = new HashMap<>()
properties.put("version", version)
properties.put("loader_version", loader_version)
properties.put("fabric_version", fabric_version)
properties.put("create_version", create_version)
properties.put("minecraft_version", minecraft_version)

properties.forEach((k, v) -> inputs.property(k, v))

filesMatching("fabric.mod.json") {
expand properties
}
}

// disable machete locally for faster builds
machete { enabled = buildNumber != null }

tasks.withType(JavaCompile).configureEach {
it.options.encoding = 'UTF-8'
it.options.release.set 17
it.options.release = 17
}

java { withSourcesJar() }
java {
// Loom will automatically attach sourcesJar to a RemapSourcesJar task and to the "build" task
// if it is present.
// If you remove this line, sources will not be generated.
withSourcesJar()

sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}

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

machete {
// disable machete locally for faster builds
enabled != null
}

remapJar {
archiveClassifier.set('dev')
// configure the maven publication
publishing {
publications {
mavenJava(MavenPublication) {
from components.java
}
}

// See https://docs.gradle.org/current/userguide/publishing_maven.html for information on how to set up publishing.
repositories {
// Add repositories to publish to here.
// Notice: This block does NOT have the same function as the block in the top level.
// The repositories here will be used for publishing your artifact, not for
// retrieving dependencies.
}
}
59 changes: 27 additions & 32 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,35 +1,30 @@
## Gradle Settings
org.gradle.jvmargs=-Xmx3G
org.gradle.daemon=false
# Done to increase the memory available to gradle.
org.gradle.jvmargs=-Xmx1G
org.gradle.parallel=true
org.gradle.caching=true

loom.platform = forge

## Gradle Plugins
loom_version = 1.3.357
vineflower_version = 1.11.0

## Mod Info
# Fabric Properties
# check these on https://fabricmc.net/develop
minecraft_version=1.20.1
yarn_mappings=1.20.1+build.10
loader_version=0.14.24
# Mappings
# https://lambdaurora.dev/tools/import_quilt.html
qm_version=23
# https://parchmentmc.org/docs/getting-started
parchment_version=2023.07.16
# Mod Properties
maven_group=com.sudolev
archives_base_name = interiors
mod_version=0.5.2
maven_group = com.sudolev

## Versions
# Minecraft: https://feedback.minecraft.net/hc/en-us/sections/360001186971-Release-Changelogs
minecraft_version = 1.20.1
# Parchment: https://parchmentmc.org/docs/getting-started
parchment_version = 2023.06.26
# Quilt Mappings - https://lambdaurora.dev/tools/import_quilt.html
quilt_mappings = 23
# NeoForge: https://neoforged.net/
neo_version = 47.1.65

## Mod Dependencies
# Create, Registrate, and Flywheel: https://github.com/Creators-of-Create/Create/wiki/Depending-on-Create#types-of-dependencies
registrate_version = MC1.20-1.3.3
create_version = 0.5.1.e-22
flywheel_version = 0.6.10-7

# JEI: https://modrinth.com/mod/jei/versions?l=forge&g=1.20.1
jei_version = 15.2.0.27
# Dependencies
fabric_version=0.90.7+1.20.1
create_version=0.5.1-d-build.1161+mc1.20.1
modmenu_version=7.2.1
# LazyDFU - https://modrinth.com/mod/lazydfu/versions
lazydfu_version=0.1.3
recipe_viewer=undefined
# JEI - https://www.curseforge.com/minecraft/mc-mods/jei/files/all
jei_version=11.5.2.1007
# REI - https://modrinth.com/mod/roughly-enough-items/versions
rei_version=9.1.580
# EMI - https://modrinth.com/mod/emi/versions
emi_version=0.6.1+1.19.2
Binary file removed gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
6 changes: 0 additions & 6 deletions gradle/wrapper/gradle-wrapper.properties

This file was deleted.

Loading

0 comments on commit 1d78a72

Please sign in to comment.