IntelliJ idea development environment settings


IntelliJ idea is a very good development tool. I used to use eclipse before. Since I came into contact with IntelliJ idea, I abandoned eclipse decisively. If I want to do something well, I must use it first. Here is a summary of the development environment settings of IntelliJ idea.

Cache path

Since the default cache path is Disk C during installation, it’s better to modify the cache path in the ${idea. Home} / bin / idea. Properties file, mainly modifying the paths of config and system files.

ignore case

I don’t know how many children’s shoes are spoiled by eclipse like me. Using automatic completion doesn’t pay attention to case at all. IntelliJ is case sensitive by default, which is very sad. However, in editor = > code completion, set case sensitive completion to none.

set number

This needs to be set in IDE settings, as shown in the figure
IntelliJ idea development environment settings

Associated navigation

When opening the file, click the small earth icon in the figure below. If you want to make all this automatic like eclipse, you can see two options: autoscroll to source and autoscroll from source in the floating layer in the figure above
IntelliJ idea development environment settings

Version control display

We certainly have version control in our development. When you used eclipse in the past, when the local file and version library were inconsistent, a * asterisk would appear in the file and the folder where it was located. You can easily see which local file has been modified, but this is not the case by default in IntelliJ. It only changes color when changing files, and does not include the parent folder. If you want to be like Eclipse, you need to check the settings as shown below. When you display colors, you can go to Settings > Editor > Colors & Fonts > File Status to adjust it, and you can adjust it to your own love.
IntelliJ idea development environment settings

Non English display of resources

In the resource bundle mode, it is quite convenient to modify an attribute. You can modify the attributes of all languages in one operation interface. All of these are done automatically, as shown in the following figure
IntelliJ idea development environment settings

Coding settings

Chinese will be displayed as Unicode code by default. In fact, just check a setting (Settings > file encodings), as shown in the following figure: after setting, all Unicode displayed can be automatically converted to the language it should be displayed; Of course, you can also set the coding format of a project separately.
IntelliJ idea development environment settings


Open file > project structure. In this section, we mainly use the red parts in the figure below

Modules: this basically includes the modules of the project. Generally speaking, eclipse's project structure is single module;
Libraries: This is basically a project library, not a global one. The imported project will generally store the data in eclipse. All the dependencies in classpath are imported as a lib library and then applied to the modules of your project;
SDKs: mainly store our JDK, as shown in the figure below (I download the JDK with source myself, so that I can directly view the Java source code related to JDK);
Global libraries: mainly public jar files. For example, several jars of servlets may be required by each project, but eclipse variables are not easy to use here, so you need to use this place to configure them, as shown in the figure below.

IntelliJ idea development environment settings

Annotation template

Template can be set for both class comments and page comments. For example, the author, time, version and other information can be automatically added when creating a class
IntelliJ idea development environment settings

Quick code template

You can set various custom shortcut code templates, such as the syso template commonly used in eclipse
IntelliJ idea development environment settings