Question

How can I stop maven from checking for updates each time I start debugging a project from Eclipse? I hope this makes sense as I'm not too familiar with the java development environment.

It's just that everytime I start debugging, it will go checking for snapshot updates for dependent libraries. And this gets annoying on a slow internet connection.

Was it helpful?

Solution

Use the -o flag if you're using the command line. From mvn -h:

-o,--offline Work offline


If you're using some sort of Maven integration like m2eclipse, the launch configurations usually have a 'Offline' check box.


Alternative: don't use SNAPSHOTs

Some might say that you're better of declaring release versions for all your plugins and dependencies, since that makes your build repeatable, i.e. instead of using

<version>1.0-SNAPSHOT</version>

use

<version>1.1</version>
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top