Repository navigation
fix(variables): drop --no-vars and let a bare Enter skip the create variables checklist - #282
Conversation
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
🔒 Security Scan Results
⏱️ SLA Breach Summary
✅ BUILD PASSED - All security checks passed |
dhruv-parekh-cs
left a comment
There was a problem hiding this comment.
Reviewed this PR's own changes on top of #281 (fcf225e..5dcf9bb): no high or medium issues. --no-vars never shipped in a release (absent from main, development and v1.11.x), so removing it breaks no released scripts. variables:set still calls chooseSources with skippable: false and requireOne: false, so it behaves as before.
Cross-repo (CL-7174): merge order is #281 → #282 → contentfly-dev-workspace#180. #180's 50-lifecycle GitHub create answers "Add environment variables" with a bare Enter, which a CLI built before #282 refuses (the checklist still requires a selection), so run the harness only against a CLI that includes #282.
— 🤖 launch-pr-review-agent (Claude)
Generated by Claude Code
1b79c28
🔒 Security Scan Results
⏱️ SLA Breach Summary
ℹ️ Vulnerabilities Without Available Fixes (Informational Only)The following vulnerabilities were detected but do not have fixes available (no upgrade or patch). These are excluded from failure thresholds:
✅ BUILD PASSED - All security checks passed |
The merge-base changed after approval.
projects:create and env:create on a terminal ask "Add environment variables" when no variable source is given. The checkbox refused an empty answer, so skipping meant moving to "Skip adding environment variables", ticking it and pressing Enter. A bare Enter with nothing ticked now skips the same way and prints the same "Skipped adding environment variables." line. The Skip choice stays, and combining it with a source is still a usage error. variables:set already accepted an empty answer and keeps its own message. #claude_code# 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com> Co-authored-by: Sakshi Koli <sakshi.koli@contentstack.com>
Variables are never required: without a terminal a create with no variable source sends an empty list and asks nothing, and on a terminal a bare Enter at "Add environment variables" now skips it. --no-vars only skipped that one checklist, so it goes, with the noVarsAlone rule and the noVars request field. Passing it is now oclif's unknown-flag error with exit 2. AGENTS.md and the README follow. The .talismanrc checksums are refreshed for every changed file the pre-push Talisman scan flags (file names, flag names and the words secret/token in prose; no secret). #claude_code# 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com> Co-authored-by: Sakshi Koli <sakshi.koli@contentstack.com>
1b79c28 to
f1d2215
Compare
🔒 Security Scan Results
⏱️ SLA Breach Summary
ℹ️ Vulnerabilities Without Available Fixes (Informational Only)The following vulnerabilities were detected but do not have fixes available (no upgrade or patch). These are excluded from failure thresholds:
✅ BUILD PASSED - All security checks passed |
dhruv-parekh-cs
left a comment
There was a problem hiding this comment.
Reviewed the whole PR at f1d2215 (rebased onto v2-dev after #281 merged, so the earlier review's commit is no longer an ancestor): no high or medium issues.
Removing --no-vars breaks no released user: the flag only ever existed on v2-dev (not on main or development, and in no tag). The chooser keeps rejecting Skip combined with other sources, and variables:set (not skippable) behaves as before on an empty pick.
— 🤖 launch-pr-review-agent (Claude)
Generated by Claude Code
What
Jira: CL-7174
projects:createandenv:createask "Add environment variables". That checkbox used to refuse an empty answer, so you had to tick "Skip adding environment variables" first. Now Enter with nothing ticked skips it and prints the sameSkipped adding environment variables.line. The Skip choice stays, and combining it with a source is still a usage error.variables:setalready accepted an empty answer and is unchanged.--no-varsis removed fromprojects:createandenv:create, along with thenoVarsAlonerule and thenoVarsrequest field. Variables are never required: a create without a terminal and with no source already sends an empty list and asks nothing, and on a terminal one Enter now skips. Passing--no-varsis now oclif's unknown-flag error, exit 2..talismanrcchecksums are refreshed for the two test files Talisman flags on file name and wording (no secret).One thing to know: whether create prompts depends on stdin being a terminal, not stdout. So a fully flagged create typed as
… > deploy.logstops at the checklist, which is drawn into the file. A--varor</dev/nullavoids that. Any missing value already behaves this way.Stacked on #281. This branch includes that PR's deps commit, so its own commits pass the Snyk pre-commit hook. Review only the two
fix(variables)commits. It will be rebased ontov2-devonce #281 merges.Tests
--no-varsunit and rule tests are removed.env:createandprojects:createon a terminal, with every other value given as a flag, ask only "Add environment variables", and a bare Enter creates with no variables.--no-varsis refused with exit 2 before any request.npm test: 193 suites, 3813 tests pass. Lint and typecheck are clean, and the changed files have 100% branch coverage.CL-7174in contentstack/contentfly-dev-workspace (PR to follow).#claude_code#
🤖 Generated with Claude Code