Skip to content

Commit

Permalink
Fix rules_java release pipeline config (#2137)
Browse files Browse the repository at this point in the history
This enables making releases at specific points even if the branch has
moved ahead.

Before this change, the release would always be made at the HEAD of
chosen branch, we should instead to do so at the specific commit that
the workflow is executed on.
  • Loading branch information
hvadehra authored Dec 6, 2024
1 parent cf6309a commit 8b037a9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pipelines/rules_java-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ steps:
command: |
echo "+++ Checking out Git branch"
git fetch origin ${BUILDKITE_BRANCH}
git checkout ${BUILDKITE_BRANCH}
git checkout ${BUILDKITE_COMMIT}
echo "+++ Getting the latest rules_java version"
contents=$(cat MODULE.bazel)
Expand All @@ -53,4 +53,4 @@ steps:
echo "+++ Creating a release on GitHub"
cd bazel-bin/distro
relnotes=$(cat relnotes.txt)
GITHUB_TOKEN=\${github_token} github-release "bazelbuild/rules_java" \${version} "\${BUILDKITE_BRANCH}" "\${relnotes}" rules_java-\${version}.tar.gz
GITHUB_TOKEN=\${github_token} github-release "bazelbuild/rules_java" \${version} "\${BUILDKITE_COMMIT}" "\${relnotes}" rules_java-\${version}.tar.gz

0 comments on commit 8b037a9

Please sign in to comment.