jira-importer commented on issue #1055: URL: https://github.com/apache/maven-scm/issues/1055#issuecomment-2964643101
**[phansson](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=phansson)** commented I now realize that the folks over at [maven-release-plugin](http://maven.apache.org/maven-release/maven-release-plugin/) have come up with a much better solution for this. They've introduced a special property, `project.scm.id`, which you can set to point to the id of the server (from settings.xml) that you want to use. In other words in your POM you would have: ```xml <properties> <project.scm.id>my-scm-server<project.scm.id> </properties> ``` And the following in your settings.xml file: ```xml <settings> <servers> <server> <id>my-scm-server</id> <username>myUser</username> <password>myPassword</password> </server> </servers> </settings> ``` I believe that is an excellent solution. It is indeed much better than my solution above. The only bewildering thing about this solution is why it was implemented in the maven-release-plugin and not in the SCM API. Oh well. Since I do not currently use the SCM API or SCM Plugin directly the solution from maven-release-plugin fits my needs. Note: This new feature was introduced in version 2.3 of the maven-release-plugin. Be careful if you are using for example Maven 3.0.5 since that version by default uses version 2.0 of the maven-release-plugin and that is just too old. Make sure to force to a later version of the maven-release-plugin if you want to use this feature. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
