GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — ci(release): also release on refactor/perf commits (keep patch-only) by Episkey-G · Pull Request #5 · Episkey-G/ucloud-cli

Conversation

@Episkey-G

@Episkey-G Episkey-G commented Jun 25, 2026

Copy link
Copy Markdown
Owner

概要

把 refactor/perf 提交纳入 release 检测器(Option C),让纯平台重构也能发版,patch-only 策略不变。

背景

原检测器只用 svu next(只认 feat/fix/breaking),导致 PR #4 的纯重构清理合并后不发版。业界对照(AWS CLI / gcloud / Azure / aliyun / gh / Terraform / semantic-release·release-please·changesets)确认「每次合并都发版(含纯重构)」并非主流;选择折中的 Option C:在 svu next 基础上额外用 git log grep 把 refactor/perf 也算可发版,其余 docs/chore/test/ci/style/build 仍跳过。

改动

  • .github/workflows/release.yml 的 "Compute next version & tag":叠加一条 grep -qE '^(refactor|perf)(\([^)]+\))?!?:',与 svu next 取或;发版仍 svu patch(+0.0.1)。
  • 更新头部注释。

验证(本地)

  • YAML 语法 valid。
  • 新检测器对真实历史 v0.3.4..HEAD 命中全部 11 个 refactor 提交 → 判定可发版。
  • 负向对照:chore/docs/ci/test/style 正确不命中、仍跳过。
  • 版本策略未变(patch-only)。

⚠️ 连带效果

合并到 master 后,workflow 会在 v0.3.4..HEAD 检测到 PR #4 已有的 refactor 提交 → 拟发 v0.3.5,但会停在 environment: release 人工审批门,批准后才发布。即:合并本 PR ≈ 给 PR#4 的重构补发 v0.3.5。

🤖 Generated with Claude Code

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

chatgpt-codex-connector[bot] reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
@Episkey-G @claude
ci(release): also release on refactor/perf commits (keep patch-only)
5a1a8fd
The release detector previously used only `svu next` (feat/fix/breaking), so a
refactor-only merge produced no release (e.g. PR #4's platform cleanup was
skipped). Add a git-log grep for refactor/perf commit types alongside svu next
so platform refactors also cut a patch release; pure docs/chore/test/ci/style/
build merges still skip. The bump stays PATCH-ONLY (svu patch) — version policy
unchanged.

Verified locally: new detector matches all 11 refactor commits since v0.3.4
(=> would release v0.3.5) and correctly ignores chore/docs/ci/test/style; YAML
validates.

Co-Authored-By: Claude Opus 4.8 <[email protected]>
chatgpt-codex-connector[bot]
chatgpt-codex-connector Bot reviewed Jun 25, 2026
View reviewed changes

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5a1a8fd9a6

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Comment thread .github/workflows/release.yml Outdated
Comment on lines +77 to +78
if git log --format='%s' "$CURRENT"..HEAD \
| grep -qE '^(refactor|perf)(\([^)]+\))?!?:'; then

@chatgpt-codex-connector chatgpt-codex-connector Bot Jun 25, 2026

Copy link
Copy Markdown

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

P2 Badge Include merge commit bodies in refactor detection

When a refactor/perf PR is merged with GitHub's normal merge commit and the branch commits have non-conventional subjects, the only conventional line is the PR title in the merge commit body; this detector streams only %s subjects, so it sees Merge pull request ... plus the branch subjects and leaves RELEASABLE empty. I checked .github/workflows/pr-gate.yml, and the gate validates only PR_TITLE rather than every commit subject, so this workflow can still skip exactly the refactor/perf-only releases this change is meant to enable unless the individual commits also happen to be conventional.

Useful? React with 👍 / 👎.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@Episkey-G Episkey-G Jun 25, 2026

Copy link
Copy Markdown
Owner Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Good catch — addressed in 8d83ab6. The detector now scans %B (full message), so a refactor/perf type appearing only in a merge-commit body / PR title is caught.

Review also surfaced a blocker in the original 5a1a8fd: git log | grep -q under the Actions default bash -o pipefail made git log take SIGPIPE on grep's early exit, flipping the pipeline non-zero and wrongly skipping the release (reproduced on the real v0.3.4..HEAD range). Fixed by capturing to a var and matching via here-string (no pipe). Verified under bash -eo pipefail: real range → release, merge-body type → release, chore/docs/ci/test/style → skip, 5M-line input → no SIGPIPE.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@Episkey-G @claude
ci(release): make refactor/perf detector pipefail-safe and merge-body…
8d83ab6
…-aware

Two fixes from PR #5 review:
- BLOCKER (self-review): 'git log | grep -q' under bash -o pipefail (the GitHub
  Actions default shell) makes git log take SIGPIPE when grep matches early,
  flipping the whole pipeline non-zero, so the release is WRONGLY SKIPPED —
  reproduced on the real v0.3.4..HEAD range (printed NO-MATCH despite 11
  matching refactor commits). Capture git log to a var and match via here-string
  (no pipe -> no SIGPIPE).
- P2 (Codex): scan %B (full commit message) instead of %s, so a refactor/perf
  type that only appears in a merge-commit body / PR title is also detected.

Verified under bash -eo pipefail: real range -> release; merge-body-only type
-> release; chore/docs/ci/test/style -> skip; 5M-line input -> no SIGPIPE.

Co-Authored-By: Claude Opus 4.8 <[email protected]>
@Episkey-G
Episkey-G merged commit 0c700a7 into master Jun 25, 2026
10 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@Episkey-G
Episkey-G deleted the ci/release-include-refactor branch June 25, 2026 08:24
@Episkey-G Episkey-G mentioned this pull request Jun 25, 2026
ci: P2a 准入 gate(owner-gate + 原生 auto-merge)+ rule7/8 + products.yaml 拆分 #6
Merged
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@chatgpt-codex-connector chatgpt-codex-connector[bot] chatgpt-codex-connector[bot] left review comments

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@Episkey-G
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.