diff --git a/src/main/groovy/de/gliderpilot/gradle/semanticrelease/UpdateGithubRelease.groovy b/src/main/groovy/de/gliderpilot/gradle/semanticrelease/UpdateGithubRelease.groovy index a65ca4b..cde37bf 100644 --- a/src/main/groovy/de/gliderpilot/gradle/semanticrelease/UpdateGithubRelease.groovy +++ b/src/main/groovy/de/gliderpilot/gradle/semanticrelease/UpdateGithubRelease.groovy @@ -20,6 +20,7 @@ import org.gradle.api.DefaultTask import org.gradle.api.logging.Logger import org.gradle.api.logging.Logging import org.gradle.api.tasks.Input +import org.gradle.api.tasks.Internal import org.gradle.api.tasks.TaskAction class UpdateGithubRelease extends DefaultTask { @@ -38,6 +39,7 @@ class UpdateGithubRelease extends DefaultTask { project.version.inferredVersion } + @Internal protected String getTagName() { project.release.tagStrategy.toTagString(version.version) } @@ -47,10 +49,12 @@ class UpdateGithubRelease extends DefaultTask { return repo.releaseAssets } + @Internal GithubRepo getRepo() { project.semanticRelease.repo } + @Internal SemanticReleaseChangeLogService getChangeLog() { project.semanticRelease.changeLog } diff --git a/src/test/groovy/de/gliderpilot/gradle/semanticrelease/integration/SemanticReleasePluginIntegrationSpec.groovy b/src/test/groovy/de/gliderpilot/gradle/semanticrelease/integration/SemanticReleasePluginIntegrationSpec.groovy index 2fead95..17d6051 100644 --- a/src/test/groovy/de/gliderpilot/gradle/semanticrelease/integration/SemanticReleasePluginIntegrationSpec.groovy +++ b/src/test/groovy/de/gliderpilot/gradle/semanticrelease/integration/SemanticReleasePluginIntegrationSpec.groovy @@ -89,6 +89,13 @@ class SemanticReleasePluginIntegrationSpec extends IntegrationSpec { def setupGradleProject() { buildFile << """ apply plugin: 'de.gliderpilot.semantic-release' + semanticRelease { + repo.ghToken = 'anything' + repo.useGhEnterprise('https://example.com') + } + tasks.updateGithubRelease.actions.clear() + tasks.updateGithubRelease.doFirst { + } """.stripIndent() }