If you get the error:
Unbound classpath variable: 'M2_REPO/...' in project '...' it means you have not setup your M2_REPO variable as a classpath variable in Eclipse. To fix this:
- Open Eclipse Preferences
- Go to Java -> Build Path -> Classpath Variables
- Add a variable named M2_REPO
- Click Folder... and select your repository folder. This will be in user home directory under .m2, ie /Users/AUser/.m2/repository
You can also do this by running the following maven command:
mvn -Declipse.workspace=<path-to-eclipse-workspace> eclipse:add-maven-repo
