Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Command Line Arguments


Frost19
 Share

Recommended Posts

Hello Everyone this is my first post so sorry if I screw it up,

 

I am looking for a way to specify the mods folder via command line arguments maybe something like this

 

java -jar forge.jar --mods "<mods-folder>"

Link to comment
Share on other sites

There are three command line arguments you can use for this.

  • --mavenRoots - this must be set to a list of directories (relative to .minecraft or absolute) to search for (comma separated). These directories will be searched for any mods you specify with the other two arguments.
  • --mods - this can be set to a list of comma separated mod "coordinates". This has a format of 
    <groupId>:<artifactId>[:<classifier>]:<version>[@extension] (things in [ ] are optional).
    groupdId will be split into parts separated by . (if there are any dots).
    The file name will be constructed: artifactId-version-classifier.extension (extension defaults to .jar and classifier can be left out).
    The final path will then be:
    groupId/parts/go/here/artifactId/version/filename

    Each of these paths will then be looked for in the mavenRoots you've given with the mavenRoots argument.
  • --modLists - this can be set to a list of comma separated mod list files (relative to .minecraft or absolute). The file name must end with ".list". These files must be normal text files, each line represents a mod coordinate like described above.

Disclaimer: I've not used this, this is written from reading through the code. Also I don't know if anyone actually uses this (looking at you Curse launcher!!!).

Edited by diesieben07
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share



×
×
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.