Skip to content

Commit

Permalink
Mark the output changelog task as not compatible with the configurati…
Browse files Browse the repository at this point in the history
…on cache
  • Loading branch information
pupnewfster committed Jun 27, 2024
1 parent 84bd9a5 commit 8bee5f5
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 9 deletions.
17 changes: 8 additions & 9 deletions .github/workflows/gradle-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,19 +51,22 @@ jobs:
build/neoForm
~/.gradle
.gradle
- name: Validate Gradle Wrapper
uses: gradle/actions/wrapper-validation@v3
- name: Setup Java
uses: actions/setup-java@v4
with:
java-version: 21
distribution: 'temurin'
settings-path: ${{ github.workspace }} # location for the settings.xml file

- name: Build with Gradle
uses: gradle/gradle-build-action@v3
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
with:
arguments: build outputChangelog
gradle-version: wrapper
cache-read-only: false

- name: Build with Gradle
run: ./gradlew build outputChangelog
env:
BUILD_NUMBER: ${{ github.run_number }}
GIT_COMMIT: ${{ github.sha }}
Expand All @@ -86,11 +89,7 @@ jobs:
target_commitish: ${{ github.sha }}

- name: Publish
uses: gradle/gradle-build-action@v3
with:
arguments: curseforge modrinth publish
gradle-version: wrapper
cache-read-only: false
run: ./gradlew curseforge modrinth publish
env:
CURSEFORGE_KEY: ${{ secrets.CURSEFORGE_KEY }}
MODRINTH_TOKEN: ${{ secrets.MODRINTH_TOKEN }}
Expand Down
2 changes: 2 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -645,6 +645,8 @@ def changeLogResolver = { ->
}

tasks.register('outputChangelog') {
//TODO: Can we make this compatible with the configuration cache?
notCompatibleWithConfigurationCache('Not yet compatible')
doLast {
project.file('build/changelog.md').text = changeLogResolver.call()
}
Expand Down

0 comments on commit 8bee5f5

Please sign in to comment.