IntelliJ IDEA modifies the system cache directory

When intellij IDEA is started for the first time, a folder starting with .IntelliJIdea will be created in the ${ user.home} directory to store IDEA's configuration information, plugins and cache information. This folder will grow larger as the tool is used for more time. If the user directory and the system disk are in the same partition, the free space of the system disk partition will become smaller, and the directory will be deleted when the system is reinstalled.

So we need to modify this directory to other partitions. The modification is very simple, as follows:

Find the idea.properties file in the bin folder of the IDEA installation directory. We need several items in it:

 

# Use ${idea.home} macro to specify location relative to IDE installation home.
# Use ${xxx} where xxx is any Java property (including defined in previous lines of this file) to refer to its value.
# Note for Windows users: please make sure you're using forward slashes (e.g. c:/idea/system).

#---------------------------------------------------------------------
# Uncomment this option if you want to customize path to IDE config folder. Make sure you're using forward slashes.
#---------------------------------------------------------------------
#Open the configuration of confi
# idea.config.path=${user.home}/config
 
#---------------------------------------------------------------------
# Uncomment this option if you want to customize path to IDE system folder. Make sure you're using forward slashes.
#---------------------------------------------------------------------
#Open system configuration
# idea.system.path=${user.home}/system
 
#---------------------------------------------------------------------
# Uncomment this option if you want to customize path to user installed plugins folder. Make sure you're using forward slashes.
#---------------------------------------------------------------------
#Open the configuration of plugins
# idea.plugins.path=${idea.config.path}/plugins
 
#---------------------------------------------------------------------
# Uncomment this option if you want to customize path to IDE logs folder. Make sure you're using forward slashes.
#---------------------------------------------------------------------
#Open log configuration
# idea.log.path=${idea.system.path}/log

 Change the ${user.home} in idea.config.path and idea.system.path to the location where the directory will be stored. I modified it to D:/Program/JetBrains here. The following is the modified result

 

 

#---------------------------------------------------------------------
# Uncomment this option if you want to customize path to IDE config folder. Make sure you're using forward slashes.
#---------------------------------------------------------------------
idea.config.path=D:/Program/JetBrains/.IntelliJIdea/config

#---------------------------------------------------------------------
# Uncomment this option if you want to customize path to IDE system folder. Make sure you're using forward slashes.
#---------------------------------------------------------------------
idea.system.path=D:/Program/JetBrains/.IntelliJIdea/system

 Note: Be sure to remove the comment character (#) in front of the configuration item, otherwise it will not take effect.

 

 Next, restart the IDEA tool.

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=327083983&siteId=291194637