Skip to content

Commit 9ef79ec

Browse files
committed
Initial public commit
All work has been condensed into this single commit.
0 parents  commit 9ef79ec

File tree

17 files changed

+942
-0
lines changed

17 files changed

+942
-0
lines changed

.gitattributes

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
* text eol=lf
2+
*.bat text eol=crlf
3+
*.java text eol=lf
4+
*.gradle text eol=crlf

.github/workflows/publish.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Publish
2+
3+
on:
4+
push:
5+
branches: [ 'master' ]
6+
paths-ignore:
7+
- '.github/workflows/**'
8+
- 'README.md'
9+
- 'settings.gradle'
10+
11+
permissions:
12+
contents: read
13+
14+
jobs:
15+
build:
16+
uses: MinecraftForge/SharedActions/.github/workflows/gradle.yml@v0
17+
with:
18+
java: 21
19+
gradle_tasks: 'check publish'
20+
artifact_name: 'slime-launcher'
21+
secrets:
22+
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }}
23+
PROMOTE_ARTIFACT_WEBHOOK: ${{ secrets.PROMOTE_ARTIFACT_WEBHOOK }}
24+
PROMOTE_ARTIFACT_USERNAME: ${{ secrets.PROMOTE_ARTIFACT_USERNAME }}
25+
PROMOTE_ARTIFACT_PASSWORD: ${{ secrets.PROMOTE_ARTIFACT_PASSWORD }}
26+
MAVEN_USER: ${{ secrets.MAVEN_USER }}
27+
MAVEN_PASSWORD: ${{ secrets.MAVEN_PASSWORD }}
28+
GRADLE_CACHE_KEY: ${{ secrets.GRADLE_CACHE_KEY }}

.gitignore

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
/**/.gradle/
2+
/**/.classpath
3+
/**/.project
4+
/**/.settings/
5+
/**/bin/
6+
/**/test/
7+
/**/build/
8+
/repo/
9+
/cache/
10+
/_old_mdks_/
11+
12+
# Tool Output - Jonathan uses the run directory
13+
/run/
14+
/output/
15+
16+
# Jonathan's IntelliJ Fuckery
17+
/.idea/

LICENSE-header.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Copyright (c) Forge Development LLC and contributors
2+
SPDX-License-Identifier: LGPL-2.1-only

README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Minecraft Slime Launcher
2+
3+
A slim launcher for Minecraft in the development environment.
4+
5+
## Requirements (Delete on Release)
6+
7+
- The ability to launch Minecraft paired with ForgeGradle 7.
8+
- Down the road, we will want to be able to launch versions of Minecraft that use Java 8, old Bootstrap, and old FML.
9+
10+
## Purpose
11+
12+
SlimeLauncher is a standalone tool that allows users to launch Minecraft without needing to interface with the standard
13+
Minecraft Launcher or third party solutions. ForgeGradle 6 and older have done this in the past, but creating a
14+
standalone tool to do this allows for better separation of code and brings potential for other use cases down the line.

build.gradle

Lines changed: 105 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,105 @@
1+
import com.github.jengelman.gradle.plugins.shadow.tasks.ShadowJar
2+
3+
plugins {
4+
id 'java'
5+
id 'idea'
6+
id 'eclipse'
7+
id 'maven-publish'
8+
alias libs.plugins.licenser
9+
alias libs.plugins.gradleutils
10+
alias libs.plugins.shadow
11+
}
12+
13+
final projectDisplayName = 'Slime Launcher'
14+
final projectArtifactId = base.archivesName = 'slime-launcher'
15+
final projectVendor = 'Forge Development LLC'
16+
description = 'A slim launcher for Minecraft in the development environment.'
17+
group = 'net.minecraftforge'
18+
version = gitversion.tagOffset
19+
20+
println "Version: $version"
21+
22+
java {
23+
// Even though older Minecraft supports as far back as 1.5, 8 is compatible with it, and SL is not compiling anything.
24+
toolchain.languageVersion = JavaLanguageVersion.of 8
25+
26+
withSourcesJar()
27+
}
28+
29+
dependencies {
30+
implementation libs.gson
31+
implementation libs.jopt
32+
33+
implementation libs.bundles.utils
34+
35+
compileOnly libs.nulls
36+
}
37+
38+
license {
39+
header rootProject.file('LICENSE-header.txt')
40+
newLine false
41+
exclude '**/*.properties'
42+
}
43+
44+
tasks.withType(JavaCompile).configureEach {
45+
options.encoding = 'UTF-8'
46+
}
47+
48+
tasks.named('jar', Jar) {
49+
manifest {
50+
attributes([
51+
'Main-Class': 'net.minecraftforge.launcher.Main'
52+
])
53+
attributes([
54+
'Specification-Title' : projectDisplayName,
55+
'Specification-Vendor' : projectVendor,
56+
'Specification-Version' : gitversion.info.tag,
57+
'Implementation-Title' : projectDisplayName,
58+
'Implementation-Vendor' : projectVendor,
59+
'Implementation-Version': project.version
60+
], 'net/minecraftforge/launcher/')
61+
}
62+
63+
archiveClassifier = 'thin'
64+
}
65+
66+
tasks.named('shadowJar', ShadowJar) {
67+
enableRelocation = true
68+
relocationPrefix = 'net.minecraftforge.launcher.shadow'
69+
70+
archiveClassifier = null
71+
}
72+
73+
changelog {
74+
fromBase()
75+
}
76+
77+
publishing {
78+
publications.register('mavenJava', MavenPublication) {
79+
from components.shadow
80+
81+
artifactId = projectArtifactId
82+
changelog.publish it
83+
84+
pom { pom ->
85+
name = projectDisplayName
86+
description = project.description
87+
88+
gradleutils.pom.setGitHubDetails pom
89+
90+
licenses {
91+
license gradleutils.pom.licenses.LGPLv2_1
92+
}
93+
94+
developers {
95+
developer gradleutils.pom.developers.Jonathing
96+
}
97+
}
98+
}
99+
100+
repositories {
101+
maven gradleutils.publishingForgeMaven
102+
}
103+
}
104+
105+
idea.module { downloadJavadoc = downloadSources = true }

gradle.properties

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
# Build Cache
2+
# https://docs.gradle.org/current/userguide/build_cache.html
3+
org.gradle.caching=true
4+
5+
# Parallel Project Execution
6+
# https://docs.gradle.org/current/userguide/performance.html#parallel_execution
7+
org.gradle.parallel=true
8+
9+
# Configure On Demand
10+
# https://docs.gradle.org/current/userguide/multi_project_configuration_and_execution.html
11+
org.gradle.configureondemand=true
12+
13+
# Configuration Cache
14+
# https://docs.gradle.org/current/userguide/configuration_cache.html
15+
#org.gradle.configuration-cache=true
16+
17+
# Parallel configuration caching
18+
# https://docs.gradle.org/current/userguide/configuration_cache.html#config_cache:usage:parallel
19+
#org.gradle.configuration-cache.parallel=true
20+
21+
# Ignoring problems with configuration cache
22+
# Fixes issues with core plugins (publish, idea, eclipse, etc.) that are not compatible with the configuration cache
23+
# https://docs.gradle.org/current/userguide/configuration_cache.html#config_cache:usage:ignore_problems
24+
#org.gradle.configuration-cache.problems=warn

gradle/wrapper/gradle-wrapper.jar

42.6 KB
Binary file not shown.
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
distributionBase=GRADLE_USER_HOME
2+
distributionPath=wrapper/dists
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-bin.zip
4+
networkTimeout=10000
5+
validateDistributionUrl=true
6+
zipStoreBase=GRADLE_USER_HOME
7+
zipStorePath=wrapper/dists

0 commit comments

Comments
 (0)