maven:如何清理本地仓库中的旧快照?

oar*_*nli 6 snapshot maven

我在我的pom.xml中使用了另一个团队开发的快照jar。一段时间后,我在本地仓库中发现了很多带有时间戳的快照jar,如下所示:

\n\n

base-0.0.1-20190924.065706-10.jar\nbase-0.0.1-20190925.002128-11.jar\nbase-0.0.1-20191107.012927-66.jar\nbase-0.0.1-20191108.002149-68.jar

\n\n

我知道我可以手动删除它们,但我认为必须有一种方法可以自动清除它们\xef\xbc\x9f\n有人知道吗?

\n

Jim*_*ers 5

mvn dependency:purge-local-repository可能有帮助。查看有关包含特定 groupId 或 artifactId 的部分。

https://maven.apache.org/plugins/maven-dependency-plugin/examples/purging-local-repository.html