Skip to content

feat(cli): add tab profile automation primitives#1398

Closed
Nikolatesla-lj wants to merge 2 commits intostablyai:mainfrom
Nikolatesla-lj:feat/cli-tab-profile-automation
Closed

feat(cli): add tab profile automation primitives#1398
Nikolatesla-lj wants to merge 2 commits intostablyai:mainfrom
Nikolatesla-lj:feat/cli-tab-profile-automation

Conversation

@Nikolatesla-lj
Copy link
Copy Markdown
Contributor

Summary

  • add browser tab inspection primitives for automation
  • add browser tab profile inspection and clone primitives
  • keep the commands under tab / tab profile so external automation can build its own rotation strategy on top

Depends on

This branch is stacked on top of the tab profile control work in #1396. Review the diff commit-by-commit or after #1396 lands.

What changed

  • added orca tab show --page <id>
  • added orca tab current [--worktree <selector|all>]
  • added orca tab profile show --page <id>
  • added orca tab profile use-default --page <id>
  • added orca tab profile clone --profile <id> [--page <id>] [--worktree <selector>]
  • added richer automation-facing tab metadata including worktree/profile fields

Why

This PR intentionally does not implement round-robin or any policy layer. Instead, it exposes the inspection and cloning primitives that an external program needs in order to safely implement its own profile selection logic.

With these commands, an external automation layer can:

  • inspect the current tab and its profile
  • read the profile bound to a specific tab
  • reset a tab to the default profile
  • clone the current page into a different profile without mutating the original tab

Tests

  • ./node_modules/.bin/vitest run src/cli/browser.test.ts src/cli/index.test.ts
  • ./node_modules/.bin/tsc --noEmit -p config/tsconfig.cli.json --composite false
  • ./node_modules/.bin/tsc --noEmit -p config/tsconfig.node.json --composite false

@Nikolatesla-lj
Copy link
Copy Markdown
Contributor Author

Closing this stacked PR after splitting its useful tab automation primitives into #1396 and keeping tab profile lifecycle in #1397. This branch was overlapping heavily with #1396 when opened directly against main.

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.

1 participant