Skip to content

Replace the Preview name positional argument with --preview-name - #519

Merged
jamesopstad merged 1 commit into
mainfrom
james/preview-name-flag
Nov 5, 2026
Merged

jamesopstad merged 1 commit into
mainfrom
james/preview-name-flag

Conversation

@jamesopstad

Copy link
Copy Markdown
Contributor

Replace the Preview name positional argument with --preview-name

This is a breaking change during the 1.0 beta: use cf previews deploy --preview-name feature instead of cf previews deploy feature. Omitting the flag still defaults to the current CI or Git branch; when no branch is available, the error now shows the flag syntax.

@ask-bonk

ask-bonk Bot commented Nov 5, 2026

Copy link
Copy Markdown
Contributor

LGTM!

github run

@pkg-pr-new

pkg-pr-new Bot commented Nov 5, 2026 •

Copy link
Copy Markdown
npm i https://pkg.pr.new/cf@519

commit: 00bd1fe

@github-actions

github-actions Bot commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor

cf --help startup

mean stddev min max
PR 283.3 ms 2.9 ms 279.4 ms 290.9 ms
base 285.4 ms 3.5 ms 280.0 ms 294.4 ms

Δ (PR vs base): ↓ -2.1 ms (-0.7%)

Measured with hyperfine on ubuntu-latest (3 warmup runs, 20 timed runs). CI numbers carry ±a few ms of runner jitter; treat small deltas as noise.

@jamesopstad
jamesopstad added this pull request to stack #521 November 5, 2026 13:06
@jamesopstad
jamesopstad marked this pull request as ready for review November 5, 2026 13:15
@jamesopstad
jamesopstad requested a review from a team as a code owner November 5, 2026 13:15

@clanky-the-clanker clanky-the-clanker Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Superseded by the review of ffe3d5ff.

This review, of a9e52a83

✅ Approved — The positional argument is replaced with the --preview-name option everywhere: the command code, the metadata, the generated JSON, the error text, the tests and the changeset. No issues found.

The decision is advisory: this review is a comment and never approves, blocks or requests changes on the pull request.


✅ All checks passed

🚀 Release: ✅ LGTM

Risk: Low. The minor changeset matches the repository's rule for pre-1.0 behaviour changes and clearly describes the breaking change.


🔒 Security: ✅ LGTM

No security-relevant changes.


📖 AGENTS.md: ✅ LGTM

The packages/cli/AGENTS.md update matches the new flag.


📋 Code Quality: ✅ LGTM

The builder, command string, metadata sidecar and generated metadata are in sync, and the tests cover the new flag.


⚡ Performance: ✅ LGTM

No performance impact.


📝 Documentation: ✅ LGTM

The error message and usage strings now show the flag syntax.


Reviewed commit: a9e52a83

@edmundhung edmundhung left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This will need follow-ups in two places that still use the positional form:

  • the docs (/cf/projects/ and /cf/ci/)
  • @vinext/cloudflare which runs cf previews deploy <name> for vinext-cloudflare previews deploy <name>.

@clanky-the-clanker clanky-the-clanker Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Superseded by the review of 00bd1fe4.

This review, of ffe3d5ff

✅ Approved — The positional argument is replaced with the --preview-name option everywhere: the command code, the metadata, the generated JSON, the error text, the tests and the changeset. No issues found.

The decision is advisory: this review is a comment and never approves, blocks or requests changes on the pull request.


✅ All checks passed

🚀 Release: ✅ LGTM

Risk: Low. The minor changeset matches the repository's rule for pre-1.0 behaviour changes and clearly describes the breaking change.


🔒 Security: ✅ LGTM

No security-relevant changes.


📖 AGENTS.md: ✅ LGTM

The packages/cli/AGENTS.md update matches the new flag.


📋 Code Quality: ✅ LGTM

The builder, command string, metadata sidecar and generated metadata are in sync, and the tests cover the new flag.


⚡ Performance: ✅ LGTM

No performance impact.


📝 Documentation: ✅ LGTM

The error message and usage strings now show the flag syntax.


Reviewed commit: ffe3d5ff — same changes as a9e52a83, so this is that commit's review (no new review was run; line numbers are as of a9e52a83)

@ask-bonk

ask-bonk Bot commented Nov 5, 2026

Copy link
Copy Markdown
Contributor

LGTM!

github run

@petebacondarwin
petebacondarwin enabled stacked auto-merge November 5, 2026 18:11
@jamesopstad
jamesopstad force-pushed the james/preview-name-flag branch from ffe3d5f to 00bd1fe Compare November 5, 2026 19:02
stacked auto-merge was automatically disabled November 5, 2026 19:02

Auto-merge was disabled for another pull request in the stack

@ask-bonk

ask-bonk Bot commented Nov 5, 2026

Copy link
Copy Markdown
Contributor

LGTM

github run

@clanky-the-clanker clanky-the-clanker Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

✅ Approved — The positional argument is replaced with the --preview-name option everywhere: the command code, the metadata, the generated JSON, the error text, the tests and the changeset. No issues found.

The decision is advisory: this review is a comment and never approves, blocks or requests changes on the pull request.


✅ All checks passed

🚀 Release: ✅ LGTM

Risk: Low. The minor changeset matches the repository's rule for pre-1.0 behaviour changes and clearly describes the breaking change.


🔒 Security: ✅ LGTM

No security-relevant changes.


📖 AGENTS.md: ✅ LGTM

The packages/cli/AGENTS.md update matches the new flag.


📋 Code Quality: ✅ LGTM

The builder, command string, metadata sidecar and generated metadata are in sync, and the tests cover the new flag.


⚡ Performance: ✅ LGTM

No performance impact.


📝 Documentation: ✅ LGTM

The error message and usage strings now show the flag syntax.


Reviewed commit: 00bd1fe4 — same changes as a9e52a83, so this is that commit's review (no new review was run; line numbers are as of a9e52a83)

@jamesopstad
jamesopstad added this pull request to the merge queue Nov 5, 2026
Merged via the queue into main with commit e5105e4 Nov 5, 2026
11 checks passed
@jamesopstad
jamesopstad deleted the james/preview-name-flag branch November 5, 2026 19:16
james-elicx added a commit to cloudflare/vinext that referenced this pull request Nov 6, 2026
cf previews deploy replaced its positional Preview name with --preview-name
(cloudflare/cf#519). Mirror that in vinext-cloudflare previews deploy and pass
the name to cf with the flag.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants