minecraftforge / installer Goto Github PK
View Code? Open in Web Editor NEWA simple installer for creating Launcher profiles
License: GNU Lesser General Public License v2.1
A simple installer for creating Launcher profiles
License: GNU Lesser General Public License v2.1
The Forge installer appears to come bundled with a Forge universal jar corresponding to the installer's Forge version, so it doesn't need to download it from files.minecraftforge.net. However, this universal jar does not match the corresponding universal jar hosted on files.minecraftforge.net
$ curl -s http://files.minecraftforge.net/maven/net/minecraftforge/forge/1.8.9-11.15.1.1722/forge-1.8.9-11.15.1.1722-universal.jar | md5
5cbb7db3d2b29971565fb96f9f6aadd9
$ curl -sO http://files.minecraftforge.net/maven/net/minecraftforge/forge/1.8.9-11.15.1.1722/forge-1.8.9-11.15.1.1722-installer.jar
$ unzip forge-1.8.9-11.15.1.1722-installer.jar forge-1.8.9-11.15.1.1722-universal.jar
Archive: forge-1.8.9-11.15.1.1722-installer.jar
inflating: forge-1.8.9-11.15.1.1722-universal.jar
$ md5 forge-1.8.9-11.15.1.1722-universal.jar
MD5 (forge-1.8.9-11.15.1.1722-universal.jar) = 15f859d0b206a83698621e50b418888b
Note the differing md5 checksums. 5cbb7db3d2b29971565fb96f9f6aadd9
appears to be the valid md5 checksum according to this, while 15f859d0b206a83698621e50b418888b
is not listed at all. If we dig a little deeper, extracting both universal jars and diff
ing the directories shows the following: https://clbin.com/yfGTx
It appears that the universal jar downloaded from files.minecraftforge.net contains META-INF/FORGE.SF
and META-INF/FORGE.DSA
, as well as thousands of SHA-256-Digest
entries in MANIFEST.MF
.
Furthermore, attempting to run the server using the universal jar downloaded from the site rather than the one bundled with the installer yields the following:
[16:45:12] [main/INFO] [LaunchWrapper]: Loading tweak class name net.minecraftforge.fml.common.launcher.FMLServerTweaker
[16:45:12] [main/INFO] [LaunchWrapper]: Using primary tweak class name net.minecraftforge.fml.common.launcher.FMLServerTweaker
[16:45:12] [main/INFO] [LaunchWrapper]: Calling tweak class net.minecraftforge.fml.common.launcher.FMLServerTweaker
2016-02-07 16:45:12,479 ERROR Error processing element TerminalConsole: CLASS_NOT_FOUND
2016-02-07 16:45:12,479 ERROR Error processing element TerminalConsole: CLASS_NOT_FOUND
2016-02-07 16:45:12,918 ERROR Unable to locate appender Console for logger com.mojang
2016-02-07 16:45:12,918 ERROR Unable to locate appender FmlConsole for logger
2016-02-07 16:45:12,919 ERROR Unable to locate appender Console for logger net.minecraft
2016-02-07 16:45:14,744 ERROR Error processing element TerminalConsole: CLASS_NOT_FOUND
2016-02-07 16:45:14,744 ERROR Error processing element TerminalConsole: CLASS_NOT_FOUND
2016-02-07 16:45:15,192 ERROR Unable to locate appender Console for logger com.mojang
2016-02-07 16:45:15,193 ERROR Unable to locate appender FmlConsole for logger
2016-02-07 16:45:15,193 ERROR Unable to locate appender Console for logger net.minecraft
I tried to make a Minecraft 1.16.5 server with forge 36.2.0, but it can't download the version manifest on the launcher meta of mojang.
I have checked internet connection but that's just fine.
Also, this happens every time I install with the server option, client option works just fine.
I'm using Java 1.8.0 Build 312 (Eclipse Temurin). And should be compatible.
And if I open launchermeta.mojang.com
in browser it just gets an access denied (which isn't an unknown host or something):
<Error>
<Code>AccessDenied</Code>
<Message>Access Denied</Message>
<RequestId>GP11CS5984S5534M</RequestId>
<HostId>...</HostId>
</Error>
Removed the host id, because idk if it's private or not.
Both the check on the website and the log where both done on the same machine, and connected with the same network connection.
JVM info: Temurin - 1.8.0_312 - 25.312-b07
java.net.preferIPv4Stack=true
Found java version 1.8.0_312
<html><a href='https://www.creeperhost.net/'>Data kindly mirrored by CreeperHost</a></html>
Extracting main jar:
Extracted successfully
Considering minecraft server jar
java.net.UnknownHostException: launchermeta.mojang.com
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:184)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:607)
at sun.security.ssl.SSLSocketImpl.connect(SSLSocketImpl.java:288)
at sun.net.NetworkClient.doConnect(NetworkClient.java:175)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:463)
at sun.net.www.http.HttpClient.openServer(HttpClient.java:558)
at sun.net.www.protocol.https.HttpsClient.<init>(HttpsClient.java:264)
at sun.net.www.protocol.https.HttpsClient.New(HttpsClient.java:367)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.getNewHttpClient(AbstractDelegateHttpsURLConnection.java:203)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect0(HttpURLConnection.java:1162)
at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:1056)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:189)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1567)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1495)
at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:480)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getResponseCode(HttpsURLConnectionImpl.java:352)
at net.minecraftforge.installer.DownloadUtils.getConnection(DownloadUtils.java:203)
at net.minecraftforge.installer.DownloadUtils.downloadManifest(DownloadUtils.java:267)
at net.minecraftforge.installer.json.Util.getVanillaVersion(Util.java:62)
at net.minecraftforge.installer.actions.ServerInstall.run(ServerInstall.java:70)
at net.minecraftforge.installer.InstallerPanel.run(InstallerPanel.java:424)
at net.minecraftforge.installer.SimpleInstaller.launchGui(SimpleInstaller.java:170)
at net.minecraftforge.installer.SimpleInstaller.main(SimpleInstaller.java:143)
Failed to download version manifest, can not find server jar URL.
I hope this is enough information.
When upgrading Forge (i.e. installing a new one when an old one already exists), the installer removes user-made changes to the profile. The most important ones are gameDir, and javaArgs. Could you please detect the upgrade scenario and keep user configuration?
removed
If you are updating Forge and therefor already have a "Forge" profile, it overwrites
gameDir
javaDir
javaArgs
resolution
This shouldn't happen.
Some forum posts have pointed me on this problem:
Some older java versions produce slightly different jars, but according to 7zip the content is identical, but as we compare the hash over the whole archive, the installer fails.
Screenshot of 7zip info of the jar produced with java 8u51:
Screenshot of 7zip info of the jar produced with latest java:
Here are both files (in case anyone wants to dig deeper what the diff is)
forge 28.0.100 both files.zip
In any case, I suggest comparing content checksums instead of archive checksums (as 7zip does), as compression can also change with future java version
Hi,
Under which license can I utilize this project (specifically its sources)?
Cheers,
Henrik
With the forgedev build system now having the option of creating an offline installer with all deps included, I thought it might be a good idea to also have this option available to users as well as third-parties that want to redistribute the installer jar.
The option in the installer would essentially download all required deps and create a new installer jar based on itself with these deps included.
Would it be possible that i can add arguments to the installer so i can force the client install?
i wanna use the installer because for better support of my launcher, but now the people press ok to install
and for server they even need to select stuff,
would it be a possible to add arguments so you can --installClient or something that people doesn't have to see the installer anymore?
and the same kind of deal for servers
"--installServer -d /user/var/....."
The releaseTime should be a value old enough to prevent interfering with vanilla "Latest" settings. You can use the time field to set when it was last modified.
Changing it has no negative aspects because the installer automatically selects the most up to date forge profile for launcher_profiles.json.
setup.jar.log : https://gist.github.com/thomas15v/b4440b3af3098f147e37.
if you run the installer with --installServer
option on windows, it freezes on:
MESSAGE: Downloading library lzma:lzma:0.0.1
.
However if you run with the GUI, everything finishes fine.
Is there a specific reason to not allow devs to to set OptionParser settings and the [target] for the ".minecraft" directory via startup arguments? Cause that seems mysteriously left out?
Forge itself and mod files somewhat follow a naming conversion.
For instance, I'd like to install Forge for 1.12.2, then the installer will create a "Forge 1.12.2-2847" (to sort by vanilla x modded) or "1.12.2 Forge 2847" (to sort by Minecraft version), instead of just "forge".
On a Mac, the Minecraft dir does not have a period. Just to keep continuity.
Hi,
I started gradlew.bat once in some folder, then realized i wanted everything in a different folder. After I deleted the folder, unziped forge somewhere else, ran "gradlew.bat setupDevWorkspace eclipse" again, the folder ".eclipse" and ".gradle" still were placed in the old directory where I installed it the first time.
I think this has to do with the DIRNAME and APP_HOME that are somehow stored...
Now I did manually move the folders and edited the .classpath file so that everything is alright. Hopefully it works like this.
Thanks for your help!
Cheers,
J
Hi, I currently maintain a launcher that has Forge support. It currently works up to 1.12.x by running --installServer and --extract, adding those jars to classpath, and then changing the main class and adding on any arguments from the json file inside of the installer jar.
What would be nice is to be able to have a --installClient for 1.13.x and up or similar, or some insight into how I could automate the installer for my launcher. I know about the new way things are done with regard to patching and obfuscation and that there seems to be some sort of build system in place. My current problem with the installer is that there's no way without interaction to produce a patched client jar for use with the game.
Unlike MultiMC, I'm fine running the installer or doing things in a hacky way in the pursuit of having things work. So I'm open to any option I can get to get this working.
I noticed this because I used an 'ü' in the file path. This works very good but as soon as you run the forge installer it updfates the forge profile and thus rewriting the profiles-file. After this change the ü is changed to something like this '�'. Thew vanilla launcher uses ANSI as encoding.
EDIT:
after loking into the code the file is openend and gets saved as UTF-8 and not as ANSI (ISO_8859_1) as the launcher does. (https://github.com/MinecraftForge/Installer/blob/master/src/main/java/net/minecraftforge/installer/ClientInstall.java#L284-L319)
For strange reason on fresh install's of Minecraft/Forge when the launcher is attempting to download "Scala-Libary/Compiler" it fails to do so. So I am having to copy over copy's of Scala from another machine. Is this an issue with the installer or a problem of where Scala is coming from? It could be working, but I left it running for 30 mins and it still did not end up downloading the Scala libraries.
Could a --installClient
headless option be added similar to the --installServer
option? Preferably with an optional directory argument, if omitted it should use the autodetected path similar to the default in the GUI.
When downloading the release or downloading the zipped sourcecode, the git directory is not included, causing an exception when running gradlew build
on Windows.
> Configure project :
No git repository found for :. Accessing grgit will cause an NPE.
FAILURE: Build failed with an exception.
* Where:
Build file 'C:\CENSORED\Installer-2.0\build.gradle' line: 31
* What went wrong:
A problem occurred evaluating root project 'installer'.
> Cannot invoke method describe() on null object
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at https://help.gradle.org
BUILD FAILED in 2m 10s
I using Mac OS X 10.8.4, Apple Java 6.
Run the installer, appear blank window only have one button Accept? Agree?.
(I'm not using english environment, button caption is printed my native language)
Click button or press Command + Q(quit) not working.
Looking the the repository in its current state, it is not clear how to use this software without reading code. Having a brief guide on how to use this installer would make it a lot easier to use. This should be written or referred to in the README.md
file.
Stacktrace from the launcher:
com.google.gson.JsonSyntaxException: java.net.MalformedURLException: no protocol:
at com.google.gson.Gson.fromJson(Gson.java:818) ~[launcher.1.6.91.jar:1.6.91]
at com.google.gson.Gson.fromJson(Gson.java:768) ~[launcher.1.6.91.jar:1.6.91]
at com.google.gson.Gson.fromJson(Gson.java:717) ~[launcher.1.6.91.jar:1.6.91]
at com.google.gson.Gson.fromJson(Gson.java:689) ~[launcher.1.6.91.jar:1.6.91]
at net.minecraft.launcher.updater.LocalVersionList.refreshVersions(LocalVersionList.java:46) [launcher.1.6.91.jar:1.6.91]
at net.minecraft.launcher.updater.MinecraftVersionManager.refreshVersions(MinecraftVersionManager.java:60) [launcher.1.6.91.jar:1.6.91]
Question:
Is Is downloads
blockurl
really needed if we don't download the forge jar?
(Edit: I guess I need coffee. I wanted to ask about empty url, but I wrote about downloads
block 😅)
Solutions:
downloads
blockurl
Some cities in China blocks and redirects request to files.minecraftforge.net/, which would result in crashes. Using HTTPS can avoid the issue.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.