Setup IDE Eclipse
Most of the team uses the free Java IDE Eclipse to work on JDownloader.
JDownloader's Sourcecode is stored on a code „Subversion“ server. To Check out the latest code, and to commit changes, you need a Subversion client.
We prefer an integrated solution, and thus use the Eclipse addon Subclipse as Subversion client.
Install all required tools
- Any supported Java JDK: OpenJDK, Adoptium, AdoptOpenJDK, Oracle, IBM, Zulu, Zing, Corretto, Microsoft
- Eclipse IDE for Java Developers
Set up Eclipse
Start Eclipse. Eclipse will ask you to choose your workspace.
This is the folder where Eclipse will save all your code and project settings.
Add the installed Java JDK:
Click on Window -> Preferences
Navigate to Java -> Installed JREs
If your preferred JDK is not listed or the list is empty, click [Add], Select "Continue with Standard VM" -> [Next] and select [Directory] to choose your JDK install directory.
Usually this is something like C:\Program Files\Java\jdk1.8.0_202 (for Windows)
Select your preferred JDK and click on [Apply and close]
- Click on [Help] -> [Eclipse Marketplace...]
- Search for Subclipse and click the [Install] button on the right side.
- Do not modify preselected features and click on [Confirm]
- Read- and agree to TOS -> [Finish]
- In case you get a prompt "Do you trust unsigned content of unknown origin", hit the checkbox in the "Type" column and click on "Trust selected".
If you want you can manually check the sources in beforehand for trustworthiness.
- Restart Eclipse once it prompts you to do so.
- Choose Menu →[File]→[New]→[Project] (Not 'Java-Project')
- Choose [Checkout Project from SVN] and click [Next]. Choose „Create new respository location“ in the next screen.
- Enter the first project svn url:
- Confirm checking out the root of that reepository if Eclipse asks you:
- Click [Finish] and Approve all question dialogs with [Yes] or [OK]. Eclipse will download and set up the project now.
Close the Welcome Screen to see the first project.
When adding the SVN repository, you should see a progress indicator in the bottom right corner of Eclipse. If you get an error at this point, do not see a directory structure under the SVN container, or if you are stuck at 0% this is most likely due to not having proper permissions on your firewall.
Add all outgoing ports (0:65535) on your firewall to IP addresses of svn.jdownloader.org and svn.appwork.org (or whitelist domains) and try the previous steps again.
After checking out the first project, your Eclipse window should look similar to the following screenshot:
Now repeat these steps with:
In Eclipse's Package Explorer tab, expand the "JDownloader" project and navigate to:
Find the file
Main.java , right-click on it -> Run as -> Java Application
The first start may take some time.
You may now test out the latest developer build of JDownloader and familiarize yourself with the code.
If you want you can modify Program arguments and VM arguments as follows:
Find the file
Main.java , right-click on it, select Run As -> Run Configuration -> Doubleclick on "Java Application"
A Run Configurations menu will open.
Configuring AppWork Code Formatter
In order to keep code layouts the same between the different contributors IDE setups, we prefer all commits be made using our code formatter.
- Go to Window -> Preferences -> Java -> Code Style -> Formatter and click on "Import"
- Select the file located under:
Click on [Open], then hit [Apply and Close]
How to debug a jar file in eclipse
- Start JDownloader with the following additional parameters:
java -Xmx512m -Xdebug -Xrunjdwp:transport=dt_socket,server=y,address=8000,suspend=y -jar JDownloader.jar
- Open Eclipse:
Debug Configurations→Remote Java Application.
Select JDownloader project and port 8000 and start debugging.
How can I upload/commit/write my changes?
To upload to your code server, you need write access. Basically, everybody can get write access.
To get write access, please write an E-Mail with the following content to firstname.lastname@example.org:
Username (Your code will be published under this name)
Allowance to relicense your commits. Example:
Herby I allow AppWork GmbH, Schwabacher Straße 117, 90763 Fürth, to re-license my (as user '<YOUR USERNAME>') commits to the JDownloader Code Server (svn.jdownloader.org).
Re-licensing, in this case, means modifying and distributing my changes under a new license.
Synthetica License Warning each time after JDownloader is started
Indeed if this happens, the Synthetica License is missing.
Here are two possible solutions:
- In JDownloader go to Settings -> Advanced Settings -> Search for GraphicalUserInterfaceSettings.lookandfeeltheme -> Change the value in column "Value" to FLATLAF_LIGHT and restart JDownloader.
- Close JDownloader. Navigate to your JDownloader working dir .jd_home, start JDownloader one time outside your IDE by doubleclicking JDownloader.jar.
Let it update itself and close it again.
Once done, you should not get the warning again when starting JDownloader in your IDE.