dyslexic
edit
qrcode
+=-

IntelliJ IDE, Java SDK, and CSE LogHistory Plug-in


Updated: 2024.08.31

This page will guide you through installing the IntelliJ IDE on your own machine, setting up the JDK, and installing the CSE LogHistory Plug-in.

IMPORTANT: All JetBrains products assume that the project files are on the local machine. Since you will likely be using the lab machines, and therefore the files are mapped in from a network drive, IntelliJ might run very slowly or stop respondind altogether. This seems to happen more often under Windows than under Linux. If this happens to you, try logging in under Linux, or copy the project folder to the local machine.

Quick Links


Installing IntelliJ IDEA Community Edition on Your Own Machine


All of the computers in Euler 103, 201, 217, and 218 should already have the IntelliJ software installed for Windows and Linux, so unless you are using your own machine you may skip ahead to the next section.

  1. Go to IntelliJ IDEA.
  2. Click the Download button.
  3. Click the Download button under Community, NOT Ultimate
  4. Follow the appropriate step below for your operating system
    • On Windows, execute the downloaded binary file to install the IntelliJ software.
    • On Linux, untar the downloaded file containing the IntelliJ software to a location that you can remember.
    • On OSX, "mount" the downloaded image and drag the IntelliJ software to your desktop or Applications folder.

Installing the CSE LogHistory Plug-in


Follow the instructions below.

  1. Download the CSELogHistory.jar file from link.

  2. Open/run the IntelliJ Java IDE software.

  3. From IntelliJ IDEA welcome screen, choose Configure > Plugins. If a project is already opened, choose File > Settings, and then choose Plugins in the left panel.

  4. Click the gear icon, then click Install plugin from disk....

  5. Browse to and select the CSELogHistory.jar file.

  6. Click OK.

  7. Accept the Third-Party Plugins Privacy Note.

  8. Ensure that the CSE IntelliJ LogHistory for IntelliJ IDEA is shown in the list.

  9. Click Restart IDE.

When the plug-in is installed properly, a pop-up will show every time you open a COS 265 project. This pop-up indicates that the plug-in is recording the changes. NOTE: If you do not see this pop-up when you open a project, the plug-in is not recording. Click the Hide Balloon button to close the pop-up.

Opening the Project


When you open an IntelliJ project, be sure to open the project folder and not a regular folder, otherwise IntelliJ will not work correctly. A project folder is distinguished from a regular folder by a small black box with a white line in the bottom-right corner of folder icon.

In the screenshot below, there are two folders called P00_JavaIntro, but only one (the selected one that the mouse is hovering) is the correct project folder.

You may see a window asking if you trust the project. This security feature is asking if you would like to allow IntelliJ to execute commands in the project. There are no commands in the COS265 projects, so you may safely click on Trust Project, but it would probably be fine to click Preview in Safe Mode.

If you open the incorrect folder (not a project folder), the CSE LogHistory plug-in will present a warning below (see below).

To correct, close the project (File > Close Project), then reopen the project folder that contains a .cos265 file along with all of the other project files and folders (.idea/, src/, etc.).

Invalid VCS Root Mapping Warning


If you see a warning message in the bottom-right corner of IntelliJ stating Invalid VCS root mapping, you can safely ignore it by simply clicking the × in the top-right corner of the warning.

Setting up JDK / Java SDK


After you open an IntelliJ project, if you notice a yellow JDK "11.0.3" is not found on the disk or corrupted banner across the top of the editor and many words are colored or underlined in red, you will need to install the Java Software Development Kit (SDK or JDK) by following the steps below.

Click on the Download Amazon Corretto 11.0.21 link in the banner. This will tell IntelliJ to download and install the appropriate JDK.

After installing the JDK, IntelliJ will start indexing the symbols in the JDK. This may take a few minutes to finish. The statusbar at the bottom of IntelliJ will report the progress as a progress bar. Notice that the red squiggles are still present.

Once the JDK is indexed, all of the red squiggles should be gone in IntelliJ, and you should be able to run the project by clicking on the green play button.

IMPORTANT: You may use any JDK version later than 8, but you are not allowed to use any feature available in these later versions. I will run your code using JDK8, and your code will fail if you use these features.

Using the CSE LogHistory Plug-in to Create a Zip


Your project will need to be zipped up for submission. The CSE LogHistory plug-in makes this really easy.

IMPORTANT: Modern operating systems have built-in features to create Zip files, however the OS sometimes miss including critical files! Instead, use the two options below which are provided by the CSE LogHistory plug-in.

When you open a project, the plug-in shows a balloon with a Zip Project button.

Alternatively, click the "hamburger menu" in the top-left corner, then click Find Action... under the Help menu item. Type Zip into the textbox in the window that pops up, then click Zip Project.

Clicking either of these will generate a .zip file in the root of your project folder. The Zip file will contain nearly every file in your entire project, including your recorded log. The only exceptions are the out/ and tests/ folder, because they either contain Java binaries that are reproducible or potentially very large test files.