-
Notifications
You must be signed in to change notification settings - Fork 86
Description
Feature Summary
Allow users to customize CLI execution commands for each provider through Settings > Connections. This enables full control over how agent CLIs are invoked, including custom flags, arguments, and execution parameters.
Problem or Use Case
Currently, CLI execution flags are hardcoded in the provider registry. Users cannot:
- Use
codex --yoloinstead of--full-auto(see [feat]: use--yolofor codex #659) - Add provider-specific flags like
--search,--enable collab - Customize resume flags, default arguments, or initial prompt handling
- Use custom CLI paths or wrapper scripts
This limitation forces users to accept default behavior that may not fit their workflow or security preferences.
Proposed Solution
Add a settings modal accessible via a gear icon (⚙️) next to each detected provider in Settings > Connections. The modal provides granular control over:
| Field | Description | Example |
|---|---|---|
| CLI Command | The CLI executable to run | codex, /custom/path/claude |
| Resume Flag | Flag for resuming sessions | -c -r, --continue --resume |
| Default Args | Arguments always passed | --search --enable collab |
| Auto-approve Flag | Flag for auto-approve mode | --yolo, --dangerously-skip-permissions |
| Initial Prompt Flag | Flag for passing prompts | -p, --prompt, (empty for direct) |
Key features:
- Real-time command preview showing the final assembled command
- Shell-style argument parsing (supports quoted strings:
--message "hello world") - Reset to defaults button
- Settings persist across sessions
Implementation
I have a working implementation ready:
Changes:
src/main/settings.ts- Storage and CRUD for custom configssrc/main/ipc/connectionsIpc.ts- IPC handlerssrc/main/services/ptyManager.ts- Shell-style arg parser + config applicationsrc/renderer/components/CustomCommandModal.tsx- Settings UIsrc/renderer/components/CliProvidersList.tsx- Settings button integration
PR: Will link after this issue is created.
Related Issues
- [feat]: use
--yolofor codex #659 - [feat]: use--yolofor codex - Various requests for custom CLI flags and execution parameters
Additional Context
This is a generic solution that addresses multiple feature requests by giving users full control over CLI invocation, rather than adding individual flags one by one.