如我们所知,Maven以默认目录名.m2下载了存储库中的所有Jars到本地机器,并在Windows计算机(在用户文件夹中)或在Linux机器的Home目录中下载了该目录的位置。现在我的问题是,我们可以将.m2的名称更改为myjars或其他名称吗?
发布于 2013-03-20 06:59:56
是:
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0
http://maven.apache.org/xsd/settings-1.0.0.xsd">
<localRepository>${user.home}/.m2/repository</localRepository>
<interactiveMode>true</interactiveMode>
<usePluginRegistry>false</usePluginRegistry>
<offline>false</offline>
...
</settings>发布于 2013-03-20 06:58:07
是的,,你能做到的。但是,请确保在maven主目录的<localRepository>文件夹中的settings.xml的conf文件夹中进行适当的路径更改。
https://stackoverflow.com/questions/15517183
复制相似问题