File tree Expand file tree Collapse file tree 2 files changed +11
-7
lines changed
Expand file tree Collapse file tree 2 files changed +11
-7
lines changed Original file line number Diff line number Diff line change 1616 SPOTIFY_CLIENT_SECRET : ${{ secrets.SPOTIFY_CLIENT_SECRET }}
1717 SPOTIFY_TOKEN_STRING : ${{ github.event.inputs.spotify_test_client_token }}
1818 SPOTIFY_REDIRECT_URI : ${{ github.event.inputs.spotify_test_redirect_uri }}
19- ORG_GRADLE_PROJECT_NEXUS_USERNAME : ${{ secrets.NEXUS_USERNAME }}
20- ORG_GRADLE_PROJECT_NEXUS_PASSWORD : ${{ secrets.NEXUS_PASSWORD }}
19+ NEXUS_USERNAME : ${{ secrets.NEXUS_USERNAME }}
20+ NEXUS_PASSWORD : ${{ secrets.NEXUS_PASSWORD }}
2121 ORG_GRADLE_PROJECT_SIGNING_KEY : ${{ secrets.SIGNING_KEY }}
2222 ORG_GRADLE_PROJECT_SIGNING_PASSWORD : ${{ secrets.SIGNING_PASSWORD }}
2323 SPOTIFY_API_PUBLISH_VERSION : ${{ github.event.inputs.release_version }}
Original file line number Diff line number Diff line change @@ -36,6 +36,10 @@ buildscript {
3636// --- spotify-web-api-kotlin info ---
3737val libraryVersion: String = System .getenv(" SPOTIFY_API_PUBLISH_VERSION" ) ? : " 0.0.0.SNAPSHOT"
3838
39+ // Publishing credentials (environment variable)
40+ val nexusUsername: String? = System .getenv(" NEXUS_USERNAME" )
41+ val nexusPassword: String? = System .getenv(" NEXUS_PASSWORD" )
42+
3943group = " com.adamratzman"
4044version = libraryVersion
4145
@@ -293,6 +297,10 @@ kotlin {
293297 all { languageSettings.optIn(" kotlin.RequiresOptIn" ) }
294298 }
295299 }
300+
301+ publishing {
302+ registerPublishing()
303+ }
296304}
297305
298306publishing {
@@ -389,11 +397,6 @@ fun MavenPublication.setupPom(publicationName: String) {
389397
390398// --- Publishing ---
391399
392- // Publishing credentials (environment variable)
393- val nexusUsername: String? = System .getenv(" NEXUS_USERNAME" )
394- val nexusPassword: String? = System .getenv(" NEXUS_PASSWORD" )
395-
396-
397400fun PublishingExtension.registerPublishing () {
398401 publications {
399402 val kotlinMultiplatform by getting(MavenPublication ::class ) {
@@ -413,6 +416,7 @@ fun PublishingExtension.registerPublishing() {
413416 url = uri(if (version.toString().endsWith(" SNAPSHOT" )) snapshotsRepoUrl else releasesRepoUrl)
414417
415418 credentials {
419+ println (" username ${nexusUsername} " )
416420 username = nexusUsername
417421 password = nexusPassword
418422 }
You can’t perform that action at this time.
0 commit comments