Skip to content

Commit 6600471

Browse files
committed
build: Don't publish snapshots to GH packages
1 parent 2252e95 commit 6600471

File tree

2 files changed

+1
-3
lines changed

2 files changed

+1
-3
lines changed

.github/workflows/publish.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,6 @@ jobs:
2727
- name: Publish with Gradle
2828
run: ./gradlew publish --stacktrace
2929
env:
30-
GITHUB_USERNAME: ${{ github.actor }}
31-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3230
ORG_GRADLE_PROJECT_spongeSnapshotRepo: ${{ secrets.SPONGE_MAVEN_SNAPSHOT_REPO_URL }}
3331
ORG_GRADLE_PROJECT_spongeReleaseRepo: ${{ secrets.SPONGE_MAVEN_RELEASE_REPO_URL }}
3432
ORG_GRADLE_PROJECT_spongeUsername: ${{ secrets.SPONGE_MAVEN_REPO_USER }}

buildSrc/src/main/kotlin/org/spongepowered/configurate/build/PublishingPlugin.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ class ConfiguratePublishingPlugin : Plugin<Project> {
9090
// Configure repositories
9191
val ghPackagesUser = project.findProperty("gpr.user") as String? ?: System.getenv("GITHUB_USERNAME")
9292
val ghPackagesPassword = project.findProperty("gpr.key") as String? ?: System.getenv("GITHUB_TOKEN")
93-
if (!isRelease && ghPackagesUser != null && ghPackagesPassword != null) {
93+
if (isRelease && ghPackagesUser != null && ghPackagesPassword != null) {
9494
repositories.maven { repo ->
9595
repo.name = "GitHubPackages"
9696
repo.setUrl("https://maven.pkg.github.com/SpongePowered/Configurate")

0 commit comments

Comments
 (0)