Fix docker-ops branch placeholder handling by fqjony · Pull Request #48 · udx/reusable-workflows · GitHub
Skip to content

Fix docker-ops branch placeholder handling#48

Open
fqjony wants to merge 9 commits into
masterfrom
fix-docker-ops-branch-placeholders
Open

Fix docker-ops branch placeholder handling#48
fqjony wants to merge 9 commits into
masterfrom
fix-docker-ops-branch-placeholders

Conversation

@fqjony

@fqjony fqjony commented Jul 1, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Fix docker-ops build-arg placeholder replacement for branch names containing / or &.
  • Replace echo -e output handling with printf for multiline GITHUB_OUTPUT writes.
  • Add focused regression coverage for branch placeholder handling and document the local check.
  • Absorb the open Dependabot actions/checkout@v7 upgrade across workflows.
  • Add Dependabot GitHub Actions review automation with deterministic classification and optional Copilot risk hints.
  • Refresh generated Rabbit CI repo context and link it from README/docs maintainer surfaces.

Scope

  • Changed: reusable workflow parsing/output logic, checkout action versions, Dependabot Actions review automation, maintainer docs, generated repo context, and a small shell regression test.
  • Not changed: reusable workflow call interfaces or Docker build/publish behavior.

Related PRs

Validation

  • dev.kit repo
  • python3 /Users/jonyfq/.codex/scripts/repo_context_audit.py /Users/jonyfq/git/udx/reusable-workflows
  • bash tests/docker-ops-build-args.sh
  • Parsed all .github/workflows/*.yml files with Ruby Psych.
  • bash -n ci/review-dependabot-actions.sh
  • bash -n ci/copilot-dependabot-risk-hints.sh
  • Dry-run Dependabot review against current PR chore(deps): bump actions/checkout from 6 to 7 #47 classified it as safe and would comment/merge without writing.
  • Confirmed no remaining actions/checkout@v6, unsafe sed placeholder replacement, or echo -e "$BUILD_ARGS" pattern in workflow/test files.

Copilot AI review requested due to automatic review settings July 1, 2026 12:56

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR hardens the docker-ops reusable workflow’s Docker build-arg placeholder parsing (notably for branch names containing / and &) and updates workflow dependencies by bumping actions/checkout to v7. It also adds a small Bash regression test to prevent regressions in placeholder replacement behavior.

Changes:

  • Replace sed-based placeholder substitution with Bash parameter expansion and disable patsub_replacement to handle & safely.
  • Replace echo -e multi-line output writes with printf to emit GITHUB_OUTPUT values more reliably.
  • Add a focused regression test for {{branch}}/{{version}} placeholder handling and bump actions/checkout from v6v7 across workflows.

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
tests/docker-ops-build-args.sh Adds a Bash regression test covering placeholder replacement for branch names with / and &.
.github/workflows/docker-ops.yml Updates build-arg parsing/replacement logic and switches to printf-based multi-line output writing; bumps checkout to v7.
.github/workflows/wp-gh-release-ops.yml Bumps actions/checkout to v7.
.github/workflows/npm-release-ops.yml Bumps actions/checkout to v7 in multiple jobs.
.github/workflows/js-ops.yml Bumps actions/checkout to v7 in multiple jobs.
.github/workflows/_release.yml Bumps actions/checkout to v7 in multiple jobs.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .github/workflows/docker-ops.yml
Comment thread .github/workflows/docker-ops.yml Outdated
Copilot AI review requested due to automatic review settings July 1, 2026 12:59

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 8 out of 8 changed files in this pull request and generated 1 comment.

Comment thread .github/workflows/docker-ops.yml
Copilot AI review requested due to automatic review settings July 1, 2026 13:09

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 14 out of 14 changed files in this pull request and generated 3 comments.

Comment thread .github/workflows/docker-ops.yml
Comment thread ci/review-dependabot-actions.sh
Comment thread ci/review-dependabot-actions.sh Outdated
Copilot AI review requested due to automatic review settings July 1, 2026 13:13
@fqjony fqjony requested a review from a team July 1, 2026 13:14
@fqjony fqjony self-assigned this Jul 1, 2026
@fqjony fqjony added documentation Improvements or additions to documentation enhancement New feature or request dependencies Pull requests that update a dependency file github_actions Pull requests that update GitHub Actions code labels Jul 1, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 15 out of 15 changed files in this pull request and generated 2 comments.

Comments suppressed due to low confidence (1)

.github/workflows/docker-ops.yml:678

  • Quote $GITHUB_OUTPUT consistently when redirecting. While the path is usually space-free on GitHub-hosted runners, quoting prevents edge-case failures and matches the quoting used for the multiline write just above.
          else
            # No build args provided
            echo "build_args=" >> $GITHUB_OUTPUT
            echo "ℹ️ No build arguments provided"

Comment thread tests/docker-ops-build-args.sh
Comment thread ci/review-dependabot-actions.sh
Copilot AI review requested due to automatic review settings July 1, 2026 13:19

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 15 out of 15 changed files in this pull request and generated 2 comments.

Comment thread .github/workflows/_dependabot-actions-review.yml
Comment thread ci/review-dependabot-actions.sh Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file documentation Improvements or additions to documentation enhancement New feature or request github_actions Pull requests that update GitHub Actions code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants