You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+12-6Lines changed: 12 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -72,22 +72,26 @@ jobs:
72
72
server-id: github # Value of the distributionManagement/repository/id field of the pom.xml
73
73
username: ${{ github.actor }} # username for server authentication
74
74
password: ${{ github.token }} # password or token for authentication
75
+
75
76
- name: Build with Maven
76
77
run: mvn -B package --file pom.xml
78
+
77
79
- name: Publish to GitHub Packages Apache Maven
78
80
run: mvn deploy
81
+
79
82
- name: Set up Apache Maven Central
80
83
uses: actions/setup-java@v1
81
84
with: # running setup-java again overwrites the settings.xml
82
85
java-version: 1.8
83
86
server-id: maven
84
-
username: maven_username
85
-
password: ${{ secrets.MAVEN_CENTRAL_TOKEN }} # password from secrets store
87
+
server-username: maven_username
88
+
server-password: ${{ secrets.MAVEN_CENTRAL_TOKEN }} # password from secrets store
89
+
86
90
- name: Publish to Apache Maven Central
87
91
run: mvn deploy
88
92
```
89
93
90
-
***NOTE: The `settings.xml` file is created in the Actions $HOME directory. If you have an existing `settings.xml` file at that location, it will be overwritten***
94
+
***NOTE: The `settings.xml` file is created in the Actions $HOME directory. If you have an existing `settings.xml` file at that location, it will be overwritten. See below for using the `settings-path` to change your `settings.xml` file location.***
91
95
92
96
See the help docs on [Publishing a Package](https://help.github.com/en/github/managing-packages-with-github-packages/configuring-apache-maven-for-use-with-github-packages#publishing-a-package) for more information on the `pom.xml` file.
93
97
@@ -114,7 +118,7 @@ jobs:
114
118
PASSWORD: ${{ secrets.GITHUB_TOKEN }}
115
119
```
116
120
117
-
***NOTE: The `USERNAME` and `PASSWORD` need to correspond to the credentials environment variables used in the publishing section of your `build.gradle`..***
121
+
***NOTE: The `USERNAME` and `PASSWORD` need to correspond to the credentials environment variables used in the publishing section of your `build.gradle`.***
118
122
119
123
See the help docs on [Publishing a Package with Gradle](https://help.github.com/en/github/managing-packages-with-github-packages/configuring-gradle-for-use-with-github-packages#example-using-gradle-groovy-for-a-single-package-in-a-repository) for more information on the `build.gradle` configuration file.
120
124
@@ -135,11 +139,13 @@ jobs:
135
139
with:
136
140
java-version: 1.8
137
141
server-id: github # Value of the distributionManagement/repository/id field of the pom.xml
138
-
username: ${{ github.actor }} # username for server authentication
139
-
password: ${{ github.token }} # password or token for authentication
142
+
server-username: ${{ github.actor }} # username for server authentication
143
+
server-password: ${{ github.token }} # password or token for authentication
140
144
settings-path: ${{ github.workspace }} # location for the settings.xml file
0 commit comments