Skip to content

Commit

Permalink
Merge pull request #186 from refinedmods/feat/GH-176/disable-cache-re…
Browse files Browse the repository at this point in the history
…leases

build: disable config cache on releases
  • Loading branch information
raoulvdberge authored Sep 10, 2024
2 parents f7b092e + cbe3235 commit 91ae29f
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 8 deletions.
14 changes: 6 additions & 8 deletions .github/workflows/publish-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,13 +96,11 @@ jobs:
- name: Setup Java
uses: refinedmods/refinedarchitect/.github/actions/setup-java@develop
- name: Publish to Maven
run: ./gradlew publish
run: ./gradlew --no-configuration-cache publish
env:
# https://docs.gradle.org/current/samples/sample_publishing_credentials.html#header
ORG_GRADLE_PROJECT_GitHubPackagesUsername: ${{ env.GITHUB_ACTOR }}
ORG_GRADLE_PROJECT_GitHubPackagesPassword: ${{ secrets.GITHUB_TOKEN }}
ORG_GRADLE_PROJECT_CreeperHostUsername: ${{ secrets.CREEPERHOST_MAVEN_USERNAME }}
ORG_GRADLE_PROJECT_CreeperHostPassword: ${{ secrets.CREEPERHOST_MAVEN_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
CREEPERHOST_MAVEN_USERNAME: ${{ secrets.CREEPERHOST_MAVEN_USERNAME }}
CREEPERHOST_MAVEN_TOKEN: ${{ secrets.CREEPERHOST_MAVEN_TOKEN }}

publish-javadoc:
name: Publish Javadoc
Expand Down Expand Up @@ -164,7 +162,7 @@ jobs:
- name: Setup Java
uses: refinedmods/refinedarchitect/.github/actions/setup-java@develop
- name: Deploy to CurseForge
run: ./gradlew publishCurseforge
run: ./gradlew --no-configuration-cache publishCurseforge

deploy-modrinth:
name: Deploy to Modrinth
Expand All @@ -181,7 +179,7 @@ jobs:
- name: Setup Java
uses: refinedmods/refinedarchitect/.github/actions/setup-java@develop
- name: Deploy to Modrinth
run: ./gradlew publishModrinth
run: ./gradlew --no-configuration-cache publishModrinth

announce-discord:
name: Announce to Discord
Expand Down
4 changes: 4 additions & 0 deletions refinedarchitect-plugin/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ publishing {
maven {
name = "GitHubPackages"
url = project.uri("https://maven.pkg.github.com/" + System.getenv("GITHUB_REPOSITORY"))
credentials {
username = System.getenv("GITHUB_ACTOR")
password = System.getenv("GITHUB_TOKEN")
}
}
}
}
8 changes: 8 additions & 0 deletions refinedarchitect-plugin/src/main/kotlin/BaseExtension.kt
Original file line number Diff line number Diff line change
Expand Up @@ -103,10 +103,18 @@ open class BaseExtension(private val project: Project) {
maven {
name = "GitHubPackages"
url = project.uri("https://maven.pkg.github.com/" + System.getenv("GITHUB_REPOSITORY"))
credentials {
username = System.getenv("GITHUB_ACTOR")
password = System.getenv("GITHUB_TOKEN")
}
}
maven {
name = "CreeperHost"
url = project.uri("https://maven.creeperhost.net/release")
credentials {
username = System.getenv("CREEPERHOST_MAVEN_USERNAME")
password = System.getenv("CREEPERHOST_MAVEN_TOKEN")
}
}
}
publications {
Expand Down
4 changes: 4 additions & 0 deletions refinedarchitect-versioning/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@ publishing {
maven {
name = "GitHubPackages"
url = project.uri("https://maven.pkg.github.com/" + System.getenv("GITHUB_REPOSITORY"))
credentials {
username = System.getenv("GITHUB_ACTOR")
password = System.getenv("GITHUB_TOKEN")
}
}
}
publications {
Expand Down

0 comments on commit 91ae29f

Please sign in to comment.