My provided settings.xml contained a localRepository part with the value ~/.m2/repository and when invoking any maven command, this caused issues.
Steps to reproduce:
1 - create a settings.xml with the following content:
|The path to the local repository maven will use to store artifacts.|
| Default: ~/.m2/repository -->
2 - run mvn clean in an existing project
3 - maven will create a ~ directory in the project where it will download all artifacts to.
Apart from essentially creating a private repository for each project (which can quickly take up way more space than necessary, cause issues about missing artifacts) it may also cause issues if you try to remove it and forget to escape the ; ie if you do rm -rf ~ instead of rm -rf ''.
I also tested with maven 2.2.1 and that will blow up with errors about not being able to create /.m2/repository/<some path to an artifact>.
Both 3.0.4 and 2.2.1 were downloaded from maven.apache.org, not installed via apt/dpkg.