Skip to content

chore: adapt CLI to ink 7 - #1350

Merged
tamirdresher merged 4 commits into
devfrom
tamirdresher/ink7-adaptation
Jun 16, 2026
Merged

tamirdresher merged 4 commits into
devfrom
tamirdresher/ink7-adaptation

Conversation

@tamirdresher

@tamirdresher tamirdresher commented Jun 16, 2026 •

Copy link
Copy Markdown
Collaborator

Adapts the squad CLI to ink 7.0.6, resolving CI failures on repl-ux.test.ts.

Replaces #1322 and #1335.

ink 7 breaking changes addressed

  1. key.backspace/key.delete swap: squad CLI already used both in all branches; no change needed.
  2. key.meta no longer fires on Escape: added || key.escape to disabled-input guard in InputPrompt.tsx.
  3. useInput wrapped in discreteUpdates(): rewrote Enter/paste handler to call setValue('') synchronously (inside discreteUpdates flush).

Files changed

  • packages/squad-cli/package.json: ink 6.8.0 to 7.0.6
  • packages/squad-cli/src/cli/shell/components/InputPrompt.tsx: ink 7 keyboard/render adaptation
  • package-lock.json: regenerated

Validation

repl-ux.test.ts: 109 passed, 1 pre-existing failure (line 271 Windows separator)

Closes #1322
Closes #1335

Copilot AI review requested due to automatic review settings June 16, 2026 06:51
@github-actions

github-actions Bot commented Jun 16, 2026 •

Copy link
Copy Markdown
Contributor

🛫 PR Readiness Check

ℹ️ This comment updates on each push. Last checked: commit 96a68d1

PR Scope: 📦🔧 Mixed (product + infrastructure)

⚠️ 4 item(s) to address before review

Status Check Details
❌ Single commit 4 commits — consider squashing before review
✅ Not in draft Ready for review
❌ Branch up to date dev is 1 commit(s) ahead — rebase recommended
❌ Copilot review No Copilot review yet — it may still be processing
✅ Changeset present Changeset file found
✅ Scope clean No .squad/ or docs/proposals/ files
✅ No merge conflicts No merge conflicts
❌ Copilot threads resolved 1 unresolved Copilot thread(s) — fix and resolve before merging
✅ CI passing All checks passing

Files Changed (4 files, +4317 −4276)

File +/−
.changeset/ink7-adaptation.md +12 −0
package-lock.json +4287 −4266
packages/squad-cli/package.json +1 −1
packages/squad-cli/src/cli/shell/components/InputPrompt.tsx +17 −9

Total: +4317 −4276


This check runs automatically on every push. Fix any ❌ items and push again.
See CONTRIBUTING.md and PR Requirements for details.

@github-actions

github-actions Bot commented Jun 16, 2026 •

Copy link
Copy Markdown
Contributor

🟡 Impact Analysis — PR #1350

Risk tier: 🟡 MEDIUM

📊 Summary

Metric Count
Files changed 4
Files added 1
Files modified 3
Files deleted 0
Modules touched 2
Critical files 1

🎯 Risk Factors

  • 4 files changed (≤5 → LOW)
  • 2 modules touched (2-4 → MEDIUM)
  • Critical files touched: packages/squad-cli/package.json

📦 Modules Affected

root (2 files)
  • .changeset/ink7-adaptation.md
  • package-lock.json
squad-cli (2 files)
  • packages/squad-cli/package.json
  • packages/squad-cli/src/cli/shell/components/InputPrompt.tsx

⚠️ Critical Files

  • packages/squad-cli/package.json

This report is generated automatically for every PR. See #733 for details.

@github-actions

github-actions Bot commented Jun 16, 2026 •

Copy link
Copy Markdown
Contributor

🔒 Security Review

🔒 Security review: 1 info.

Severity Category Finding Location
ℹ️ info new-dependency 1 new/changed dependency version(s) in packages/squad-cli/package.json. Verify these packages are trusted and necessary. packages/squad-cli/package.json:192

Automated security review — informational only.

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 updates the Squad CLI to work correctly with Ink 7.0.6 by bumping the Ink dependency and adjusting useInput handling to account for Ink 7 keyboard semantics and synchronous discreteUpdates behavior.

Changes:

  • Bump ink dependency in packages/squad-cli to ^7.0.6.
  • Update InputPrompt keyboard handling (Escape handling while disabled; paste/Enter debounce refactor to clear synchronously).
  • Regenerate package-lock.json to reflect the new Ink dependency graph.

Reviewed changes

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

File Description
packages/squad-cli/src/cli/shell/components/InputPrompt.tsx Adjusts key handling and Enter/paste debounce behavior for Ink 7 input semantics.
packages/squad-cli/package.json Pins Ink to ^7.0.6 for CLI runtime compatibility.
package-lock.json Updates lockfile for Ink 7 and transitive dependency changes.

@@ -132,20 +133,25 @@ export const InputPrompt: React.FC<InputPromptProps> = ({
}

if (key.return) {
Comment thread packages/squad-cli/package.json Outdated
Comment on lines 189 to 193
"dependencies": {
"@bradygaster/squad-sdk": ">=0.9.0",
"@modelcontextprotocol/sdk": "^1.29.0",
"ink": "^6.8.0",
"ink": "^7.0.6",
"react": "^19.2.4",
Replaces #1322 and #1335. Updates Escape/backspace/delete keyboard handling
to ink 7's API; adjusts paste-detection debounce so the visual clear happens
synchronously inside discreteUpdates; adds key.escape guard to disabled path.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@tamirdresher
tamirdresher force-pushed the tamirdresher/ink7-adaptation branch from c812874 to 34d25e2 Compare June 16, 2026 07:10
@tamirdresher
tamirdresher merged commit f45f856 into dev Jun 16, 2026
14 checks passed
@tamirdresher
tamirdresher deleted the tamirdresher/ink7-adaptation branch June 16, 2026 08:18
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