调整Idea缓存目录,释放C盘空间

本文使用 Idea2024

Idea 会将一些配置默认缓存在C盘,使用久了会占用大量空间(本人的Idea占用了将近5个G,以至于不得不进行迁移)


缓存目录主要涉及以下四个目录,四个目录可以分为两组,每组目录必须一起调整

配置名 默认路径
idea.config.path C:\Users\JohnS\AppData\Roaming\JetBrains\IntelliJIdea2024.1
idea.system.path C:\Users\JohnS\AppData\Local\JetBrains\IntelliJIdea2024.1
idea.plugins.path C:\Users\JohnS\AppData\Roaming\JetBrains\IntelliJIdea2024.1\plugins
idea.log.path C:\Users\JohnS\AppData\Local\JetBrains\IntelliJIdea2024.1\log

打开 ${idea.home.path}/bin/idea.properties 配置文件,修改相关参数的路径

properties 复制代码
#---------------------------------------------------------------------
# Uncomment this option if you want to customize a path to the settings directory.
#---------------------------------------------------------------------
idea.config.path=D:/idea2024/config

#---------------------------------------------------------------------
# Uncomment this option if you want to customize a path to the caches directory.
#---------------------------------------------------------------------
idea.system.path=D:/idea2024/system

#---------------------------------------------------------------------
# Uncomment this option if you want to customize a path to the user-installed plugins directory.
#---------------------------------------------------------------------
idea.plugins.path=${idea.config.path}/plugins

#---------------------------------------------------------------------
# Uncomment this option if you want to customize a path to the logs directory.
#---------------------------------------------------------------------
idea.log.path=${idea.system.path}/log

将默认路径中的文件复制至新路径,然后重启 Idea,原来的配置不会丢失。

然后就可以删除默认路径中的文件啦,释放大量空间。


不同的版本可以参考官网文档:
https://www.jetbrains.com/help/idea/2024.1/directories-used-by-the-ide-to-store-settings-caches-plugins-and-logs.html#config-directory

相关推荐
聊浮游4 天前
JAVA2026最新全套学习资料、学习路线
java·开发语言·jvm·mysql·spring·maven·idea
vx-程序开发8 天前
springboot旅游推介平台---附源码24175
java·spring boot·python·spring cloud·eclipse·django·idea
letisgo513 天前
JDK21 + Spring AI 2.0 入场指南:2026 年 Java 开发者 AI 架构全景图
java·ai·idea·jdk21
sunburn-14 天前
Java 队列全面详解:从入门到面试实战
java·开发语言·汇编·ide·idea
Pluchon16 天前
Java个人综合项目——萌部落社区V2.0
java·python·spring·spring cloud·postman·idea
我命由我1234519 天前
Java 开发 - List subList 方法
java·windows·操作系统·list·intellij-idea·idea·intellij idea
xieliyu.21 天前
Java 线程池入门详解:线程池基础定义 + ThreadPoolExecutor 全参构造方法逐参数解析
java·开发语言·idea·javaee
suaizai_23 天前
IntelliJ IDEA 2026.2重磅升级:AI智能体与生产力革命
intellij-idea·idea
VX_bysjlw9851 个月前
基于微信小程序的宠物用品商城系统-后端74346-计算机毕设原创(免费领源码+带部署教程)
java·redis·微信小程序·eclipse·mybatis·idea·微信开发者工具
雾沉川1 个月前
DataGrip 非商业免费授权说明与完整使用实操教程
sql·idea