调整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

相关推荐
小码狐2 天前
GIT相关
git·idea·基础
小手cool3 天前
idea2025.3.3版本很卡
java·idea
深念Y4 天前
Docker Desktop 版本与 IDEA 插件兼容性
docker·云原生·容器·api·idea·wsl
Network porter4 天前
IDEA2025(2025.2)都更新了什么???
java·intellij-idea·idea
观书喜夜长6 天前
大模型应用开发学习-基于langchain框架做一个个人文档问答助手
python·学习·idea
金蕊泛流霞8 天前
【idea2023破解版】
idea
百锦再10 天前
飞算 JavaAI:我的编程强力助推引擎
java·spring·ai·编程·idea·code·飞算
稻草猫.14 天前
SpringBoot日志全解析:从调试到持久化
java·开发语言·spring boot·java-ee·idea
李小白杂货铺15 天前
IntelliJ IDEA 深度调优:禁用启动校验、休眠唤醒卡死修复与插件生态清理指南
idea·intellij·深度优化·深度调优·禁用启动校验·休眠唤醒卡死问题·插件生态清理
筱顾大牛16 天前
点评项目---分布式锁
java·redis·分布式·缓存·idea