This guide uses IntelliJ IDEA's build-in tools to generate Javadocs. There may be alternative ways to use javadoc
or ./gradlew javadoc
, and the procedure is not covered here.
-
Clone the Forge repository to your local machine. Specify an e.g.
--branch 1.18.x
option to work with an earlier version.git clone --depth 1 https://github.com/MinecraftForge/MinecraftForge.git
-
Open Forge project in IntelliJ IDEA. Click "Trust Project" if prompted. Set up the project SDK from
Top Menu Bar
-File
-Project Structure
. IDE sometimes does this automatically. -
Run
./gradlew setup
command in the terminal (or selectsetup
task from the Gradle menu). Source code from Minecraft and other relevant packages will be included later in the Javadoc. -
Delete
./projects/clean/
and./projects/fmlonly/
folders. These files cause conflicts during Javadoc generation. -
Select
Top Menu Bar
-Tools
-Generate JavaDoc...
. Choose an output directory. Set the command-line arguments like follows:-encoding utf-8 -docencoding utf-8 -charset utf-8 -windowtitle "forge 1.19.3-44.1.4" -doctitle "forge 1.19.3-44.1.4"
-
Complete by clicking "OK" button and take a break. Done.