1. 安装
IDEA 下载地址 https://www.jetbrains.com/idea/download/?section=mac
全家桶 JetBrains Toolbox
2. Maven
2.1 下载
地址 https://maven.apache.org/download.cgi?ref=marcolenzo.eu
2.2 配置环境变量
export MAVEN_HOME=/Users/xing/Documents/dev/apache-maven-3.9.6
export PATH=$PATH:$MAVEN_HOME/bin
% source ~/.zshrc
% mvn -v
2.3 配置阿里云镜像
修改配置文件 /conf/settings.xml
<settings>
<localRepository>/Users/xing/Documents/dev/repository</localRepository>
<!-- <mirror>
<id>nexus-aliyun</id>
<mirrorOf>central</mirrorOf>
<name>Nexus aliyun</name>
<url>http://maven.aliyun.com/nexus/content/groups/public</url>
</mirror> -->
<mirror>
<id>alimaven</id>
<mirrorOf>central</mirrorOf>
<name>aliyun maven</name>
<url>http://maven.aliyun.com/nexus/content/repositories/central/</url>
</mirror>
</mirrors>
</settings>
2.4 IDEA 配置 Maven
3. Git
4. 插件
4.1 Maven Helper
4.2 Alibaba Java Coding Guidelines
4.3 Lombok
5. 基础配置
5.1 快捷键设置
5.2 serialVersionUID
Editor -> Inspections -> Serializable class without 'serialVersionUID'
5.3 注释设置
Editor -> Code Style -> Java -> Code Generation
5.4 导入包设置
Imports > Class count to use import with '*'
5.5 Tab 项设置
5.6 class 模板
/**
* @author xing
* @date ${YEAR}-${MONTH}-${DAY} ${HOUR}:${MINUTE}
*/
Editor -> Inspections -> Javadoc -> Javadoc Declaration problems