Skip to content
This repository has been archived by the owner on Dec 5, 2024. It is now read-only.

Commit

Permalink
Fix missing node build execution during publish (#50)
Browse files Browse the repository at this point in the history
Description
===========

The last patch to gradle 6.9 added a small regression.
The node build task was no longer executed when calling publish.
During a normal snapshot phase that was done by calling `check` before.
But our pipelines don't call `check` during a publish flow so the
package gets published empty.

Changes
=======

* ![FIX] missing `node` build execution during publish
  • Loading branch information
Larusso authored Apr 1, 2022
1 parent 58f16a5 commit 027183f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,7 @@ class NodeReleasePluginPublishSpec extends GithubIntegrationSpec {
then:
print(result.standardOutput)
result.success
result.wasExecuted("node_run_build")
result.wasExecuted("npm_publish")
hasPackageOnArtifactory(artifactoryRepoName, packageNameForPackageJson())
config.version == version
Expand Down Expand Up @@ -211,6 +212,7 @@ class NodeReleasePluginPublishSpec extends GithubIntegrationSpec {

then:
result.success
result.wasExecuted("node_run_build")
result.wasExecuted("node_publish")
result.wasExecuted("npm_publish")
result.wasSkipped("githubPublish") != expectRelease
Expand Down
2 changes: 1 addition & 1 deletion src/main/groovy/wooga/gradle/node/NodeReleasePlugin.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ class NodeReleasePlugin implements Plugin<Project> {
assembleTask.dependsOn nodeBuildTask
// Set up publish lifecycle dependencies
nodePublishTask.dependsOn engineScopedPublishTask
publishTask.dependsOn nodePublishTask
publishTask.dependsOn nodeBuildTask, nodePublishTask
githubPublishTask.mustRunAfter nodePublishTask

// TODO: Add custom tasks previously provided by the nebula release plugin
Expand Down

0 comments on commit 027183f

Please sign in to comment.