Hello world app

This commit is contained in:
EliteMasterEric 2023-11-25 01:43:52 -05:00
commit 16b8315b7e
5 changed files with 75 additions and 0 deletions

3
.vscode/settings.json vendored Normal file
View File

@ -0,0 +1,3 @@
{
"java.configuration.updateBuildConfiguration": "interactive"
}

46
app/build.gradle Normal file
View File

@ -0,0 +1,46 @@
/*
* This file contains a sample Java application project.
*/
plugins {
// Apply the application plugin to add support for building a CLI application in Java.
id 'application'
}
repositories {
// Maven Central for core dependencies
mavenCentral()
}
version = '1.0.0'
group = "com.elitemastereric"
archivesBaseName = "helloworld"
sourceCompatibility = JavaVersion.VERSION_16
targetCompatibility = JavaVersion.VERSION_16
dependencies {
implementation "com.google.guava:guava:21.0"
}
application {
// Define the main class for the application.
mainClass = 'com.elitemastereric.helloworld.Launch'
}
jar {
manifest {
// Define main class for use with java -jar
attributes(
'Main-Class': application.mainClass
)
}
}
task buildAndCopy(type: Copy) {
group 'build'
dependsOn 'assemble'
from "build/libs/"
into "../run/"
}

View File

@ -0,0 +1,8 @@
package com.elitemastereric.helloworld;
public class Launch {
public static void main(String[] args) {
Main main = new Main();
main.execute();
}
}

View File

@ -0,0 +1,17 @@
package com.elitemastereric.helloworld;
public class Main {
public Main() {}
public void execute() {
System.out.println(getGreeting());
}
/*
* Returns a greeting.
* This is the function which will act as the target of our Mixin.
*/
public String getGreeting() {
return "Hello World!";
}
}

View File

@ -0,0 +1 @@
This is the app which is the target for the mod loader.