DarchetypeCatalog参数详解
IDEA新建maven项目时,如果勾选archetype模板,需要指定一个archetype-catalog.xml文件。
archetypeCatalog,可选值为:remote,internal ,local等,用来指定archetype-catalog.xml文件从哪里获取。
默认为remote,从国外某网站下载archetype-catalog.xml文件。文件约为3-4M,下载速度很慢,导致创建过程卡住。
解决:下面的界面添加一个属性,archetypeCatalog = internal即可
指定archetypeCatalog为internal,即可使用maven默认的archetype-catalog.xml,而不用再remote下载
上面的方法,每次创建maven项目都要这么指定有点麻烦,有一劳永逸的方法
打开IDEA,点击configure–>setting
给VM Options添加这条参数-DarchetypeCatalog=interna