Skip to content

Instantly share code, notes, and snippets.

@sammyrulez
Created February 2, 2019 09:41
Show Gist options
  • Save sammyrulez/83793eea91361005cfb84883df79a96d to your computer and use it in GitHub Desktop.
Save sammyrulez/83793eea91361005cfb84883df79a96d to your computer and use it in GitHub Desktop.
Maven settings templating with env variable
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
 xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0
 https://maven.apache.org/xsd/settings-1.0.0.xsd">
 <servers>
 <server>
 <id>xyz-releases</id>
 <username>${my.repo.user}</username>
 <password>${my.repo.password}</password>
 </server>
 <server>
 <id>xyz-snapshots</id>
 <username>${my.repo.user}</username>
 <password>${my.repo.password}</password>
 </server>
 </servers>
</settings>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment