IntelliJ IDEA安装配置,IntelliJ IDEA优化配置git
IntelliJ IDEA配置Maven,IntelliJ IDEA配置Tomcatspring
IntelliJ IDEA设置编码,IntelliJ IDEA设置自动编译sql
IntelliJ IDEA设置热部署数据库
================================json
©Copyright 蕃薯耀 2021-01-26windows
https://www.cnblogs.com/fanshuyao/缓存
1、 使用插件破解IntelliJ IDEA 2020.3.1(须要联网):springboot
详细教程见:https://shimo.im/docs/qctkkyThpTgtKpPW/readide
2、 设置主题spring-boot
官网主题下载地址:
https://plugins.jetbrains.com/
3、 设置字体和大小
4、自动导入包
5、设置鼠标滚轮修改字体大小
勾选此设置后,增长 Ctrl + 鼠标滚轮 快捷键来控制代码字体大小显
示。
设置自动提示
6、设置行号和方法分隔符
7、设置控制台缓存输出大小和编码
设置打开的文件是否多行显示,默认是单行,超出隐藏
8、设置默认的字体和大小
9、修改注释文字的颜色
Line comment:修改当行注释的字体颜色
Block comment:修改多行注释的字体颜色
Doc Comment – Text:修改文档注释的字体颜色
10、设置代码缩进
11、 设置类头的文档注释信息
/** * @author lqy * @createtime ${YEAR}-${MONTH}-${DAY} ${TIME} */
12、 设置编码
Transparent native-to-ascii conversion 主要用于转换 ascii,通常都要勾选,
否则 Properties 文件中的注释显示的都不会是中文。
十3、 设置自动编译文件
十4、 设置省电模式
IntelliJ IDEA 有一种叫作 省电模式 的状态,开启这种模式以后
IntelliJ IDEA 会关掉代码检查和代码提示等功能。因此通常也可认为这是一种 阅
读模式,若是你在开发过程当中遇到忽然代码文件不能进行检查和提示,能够来看
看这里是否有开启该功能。
十5、 设置Eclipse的快捷键
十6、 搜索命令,自定义快捷键
经常使用快捷键设置:
复制行:Duplicate Line,改为:Ctrl + D 大小写转换:Toggle Case,改为:Ctrl + Shift + U 或者Ctrl + Shift + Y 向上移动代码:Move Line Up,改为:Ctrl + Shift + 向上箭头 向下移动代码:Move Line Down,改为:Ctrl + Shift + 向下箭头 自动导包:Shift + Enter,改为:Ctrl + Shift + O(这个好像用不了) 代码提示:Basic,改为:Alt + / 行注释:comment with Line,改为:Ctrl+ /,同执行一次就取消注释 注释块:comment with Block,改为:Ctrl + Shift + / 格式化代码: reformat,改为:Ctrl + Shift + F 参数类型提示:parameter Info,改为:Ctrl + Alt+ / 搜索方法:File Structure,改为Ctrl + O 撤销:undo,Ctrl + Z 反撤销:redo,Ctrl + Y 重命名:rename,Alt + Shift + R 生成getter和构造方法:Generate,Alt + Insert 查找文件:Double Shift
快捷键自定义配置文件在:
C:\Users\用户名\AppData\Roaming\JetBrains\IntelliJIdea2020.3\keymaps
IdeaKeysFromEclipse.xml:
<keymap version="1" name="IdeaKeysFromEclipse" parent="Eclipse"> <action id="CodeCompletion"> <keyboard-shortcut first-keystroke="ctrl space" /> <keyboard-shortcut first-keystroke="alt slash" /> </action> <action id="Console.TableResult.EditValueMaximized"> <keyboard-shortcut first-keystroke="shift enter" /> <keyboard-shortcut first-keystroke="shift alt enter" /> <keyboard-shortcut first-keystroke="shift ctrl o" /> </action> <action id="EditorDuplicate"> <keyboard-shortcut first-keystroke="ctrl down" /> </action> <action id="EditorLookupDown" /> <action id="EditorScrollDown" /> <action id="HippieCompletion" /> <action id="MethodDown" /> <action id="MethodOverloadSwitchDown" /> <action id="MethodUp" /> <action id="MoveLineDown"> <keyboard-shortcut first-keystroke="shift ctrl down" /> </action> <action id="MoveLineUp"> <keyboard-shortcut first-keystroke="shift ctrl up" /> </action> <action id="OptimizeImports"> <keyboard-shortcut first-keystroke="ctrl alt o" /> </action> <action id="ParameterInfo"> <keyboard-shortcut first-keystroke="ctrl alt slash" /> </action> <action id="ResizeToolWindowDown" /> <action id="ResizeToolWindowUp" /> <action id="SearchEverywhere.NavigateToNextGroup"> <keyboard-shortcut first-keystroke="page_down" /> </action> <action id="XDebugger.MoveWatchDown"> <keyboard-shortcut first-keystroke="shift ctrl down" /> </action> </keymap>
十7、 显示文件的全路径
十8、 配置Maven
配置Maven下载源码
十9、 关闭自动更新
二10、 配置Tomcat
二11、 自定义模板
自定义模板:
for:for循环 for(int $INDEX$ = 0; $INDEX$ < $LIMIT$; $INDEX$++) { $END$ } fore:foreach循环 for ($ELEMENT_TYPE$ $VAR$ : $ITERABLE_TYPE$) { $END$ } ifb:isBlank判断 if(StringUtils.isBlank($var1$)) { $var2$ } ifnb:isNotBlank判断 if(!StringUtils.isBlank($var1$)) { $var2$ } ifln:判断List是否为空 if($var$ == null || $var$.size() < 1) { $end$ } log:打印info日志: log.info("$VAR$ = " + $VAR$); loge:打印error日志 log.error("$VAR$ = " + $VAR$); sysou:打印输出 System.out.println("$EXPR_COPY$ = " + $EXPR$); thr:抛异常 throw new RuntimeException("$var$");
二12、 当项目有问题时,能够清除缓存和索引,也会同时清除本地的修改记录。
二十3、 配置数据库(Mysql)
须要设置时区
serverTimezone=GMT+8
测试链接:
设置字符编码:
useUnicode:true
characterEncoding:utf8
设置项目默认路径:
二十4、 解决Pom文件添加依赖没引入Jar包的问题
二十5、 idea springboot热部署设置
一、 设置项目自动编译
二、 开启项目运行时自动生成
ctrl + shift + a (windows系统)
三、 引入依赖
<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-devtools</artifactId> <scope>runtime</scope> <optional>true</optional> </dependency>
四、 重启Idea(IntelliJ IDEA 2020.3.1发现不用重启就能生效)
二十6、 实用插件
一、 CamelCase:驼峰式命名和下划线命名转换
二、 Statistic:代码统计
三、 JRebel Plugin:热部署
四、 CodeGlance:代码地图(缩略图)
五、 GsonFormat:json转换实体
六、 Mybatis:
Free MyBatis plugin
MyBatisX
MyBatisPlus
MyBatisCodeHelperPro
MyBatis Log Plugin
MybatisLogFormat
七、 Maven Helper
八、 JPA:
GenerateJPA
Jpa Support
九、 GenerateAllSetter:一键调用一个对象的全部的set方法
十、 Rainbow Brackets:彩虹括号
十一、 Grep Console:控制台输出
十二、 代码提示:
Codota
AiXcoder Code Completer
1三、 .ignore:git提交时过滤掉不须要提交的文件
1四、 Alibaba Cloud Toolkit:部署
1五、 Json Parser:json格式化
================================
©Copyright 蕃薯耀 2021-01-26
https://www.cnblogs.com/fanshuyao/