Skip to content

Commit 01876d8

Browse files
authored
Merge pull request #238 from nkmr-jp/develop
Release: mentions fixes, directory detector improvements, and performance optimizations
2 parents 3a4bb92 + 3d3a74e commit 01876d8

35 files changed

+1512
-4119
lines changed

CLAUDE.md

Lines changed: 29 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -346,23 +346,37 @@ IPC response → Renderer Process
346346

347347
Total: 52 IPC channels across 9 specialized handlers
348348

349-
### Built-in Commands Hot Reload
350-
351-
Built-in command YAMLファイルの変更は自動的に検知され、リアルタイムで反映されます:
352-
353-
**仕組み:**
354-
- ファイル監視: `~/.prompt-line/built-in-commands/`
355-
- デバウンス: 300ms
356-
- アプリ再起動不要
349+
### Built-in Commands
350+
351+
Built-in commands are slash command definitions for external CLI tools (Claude Code, Codex CLI, Gemini CLI, etc.) stored as YAML files.
352+
353+
**Source files:** `assets/built-in-commands/*.yml`
354+
**Installed to:** `~/.prompt-line/built-in-commands/` (copied via `pnpm run update-built-in-commands`)
355+
356+
**Updating built-in commands to latest versions:**
357+
1. Check the latest slash commands for each CLI tool:
358+
- **Claude Code**: Check [official changelog](https://github.com/anthropics/claude-code/releases) and [docs](https://code.claude.com/docs/en/interactive-mode#built-in-commands)
359+
- **Codex CLI**: Check [source code](https://github.com/openai/codex) and [docs](https://developers.openai.com/codex/cli/slash-commands/)
360+
- **Gemini CLI**: Check [docs](https://google-gemini.github.io/gemini-cli/docs/cli/commands.html) and [releases](https://github.com/google-gemini/gemini-cli/releases)
361+
2. Edit the YAML files in `assets/built-in-commands/` (add new commands, update changed descriptions; do not remove existing commands)
362+
3. Run `pnpm run update-built-in-commands` to install to user directory
363+
364+
**YAML format:**
365+
```yaml
366+
name: claude
367+
color: amber
368+
reference: https://example.com/docs
369+
commands:
370+
- name: command-name
371+
description: Short description of what the command does
372+
argument-hint: "[optional-args]" # optional
373+
```
357374
358-
**実装パターン:**
359-
- SettingsManagerと同じchokidar + EventEmitterパターン
360-
- YAMLファイル(.yaml, .yml)のみを監視
361-
- ファイル変更時にキャッシュクリアと'commands-changed'イベント発火
375+
**Hot reload:** Changes to `~/.prompt-line/built-in-commands/` are auto-detected (chokidar, 300ms debounce) and applied without app restart.
362376

363-
**関連ファイル:**
364-
- `src/managers/built-in-commands-manager.ts` - ファイルウォッチング実装
365-
- `src/handlers/custom-search-handler.ts` - イベントリスナー
377+
**Related files:**
378+
- `src/managers/built-in-commands-manager.ts` - File watching and cache management
379+
- `src/handlers/custom-search-handler.ts` - Event listener for `commands-changed` events
366380

367381
## Platform-Specific Implementation
368382

assets/built-in-commands/claude.yml

Lines changed: 26 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,12 @@ commands:
2222
- name: chrome
2323
description: Configure Claude in Chrome (Beta) settings
2424
- name: clear
25-
description: Clear conversation history
25+
description: "Clear conversation history and free up context (aliases: /reset, /new)"
2626
- name: compact
2727
description: Compact conversation with optional focus instructions
2828
argument-hint: "[instructions]"
2929
- name: config
30-
description: Open the Settings interface (Config tab)
30+
description: "Open the Settings interface (Config tab). Alias: /settings"
3131
- name: context
3232
description: Visualize current context usage as a colored grid
3333
- name: copy
@@ -38,14 +38,21 @@ commands:
3838
description: Troubleshoot the current session by reading the session debug log
3939
argument-hint: "[description]"
4040
- name: desktop
41-
description: Hand off the current CLI session to the Claude Code Desktop app (macOS and Windows only)
41+
description: "Continue the current session in the Claude Code Desktop app (macOS and Windows only). Alias: /app"
42+
- name: diff
43+
description: Interactive diff viewer for uncommitted changes and per-turn diffs
4244
- name: doctor
4345
description: Checks the health of your Claude Code installation
4446
- name: exit
45-
description: Exit the REPL
47+
description: "Exit the CLI. Alias: /quit"
4648
- name: export
4749
description: Export the current conversation to a file or clipboard
4850
argument-hint: "[filename]"
51+
- name: extra-usage
52+
description: Set additional usage to continue working when hitting rate limits
53+
- name: fast
54+
description: Toggle Fast mode on or off
55+
argument-hint: "[on|off]"
4956
- name: feedback
5057
description: Submit feedback about Claude Code
5158
- name: fork
@@ -57,6 +64,8 @@ commands:
5764
description: Manage hook configurations for tool events
5865
- name: ide
5966
description: Manage IDE integrations and show status
67+
- name: insights
68+
description: Generate an analysis report of Claude Code sessions (project areas, operation patterns, friction points)
6069
- name: init
6170
description: Initialize project with CLAUDE.md guide
6271
- name: install-github-app
@@ -72,22 +81,26 @@ commands:
7281
- name: mcp
7382
description: Manage MCP server connections and OAuth authentication
7483
- name: memory
75-
description: Edit CLAUDE.md memory files
84+
description: Edit CLAUDE.md memory files, enable or disable auto-memory, and view auto-memory entries
7685
- name: mobile
7786
description: Show QR code to download the Claude mobile app
7887
- name: model
79-
description: Select or change the AI model (use left/right arrows to adjust effort level)
88+
description: Select or change the AI model (use left/right arrows to adjust effort level). Takes effect immediately
8089
- name: output-style
8190
description: Set the output style directly or from a selection menu
8291
argument-hint: "[style]"
92+
- name: passes
93+
description: Share a free 1-week Claude Code pass with friends (only shown for eligible accounts)
8394
- name: permissions
84-
description: View or update permissions
95+
description: "View or update permissions. Alias: /allowed-tools"
8596
- name: plan
8697
description: Enter plan mode directly from the prompt
8798
- name: plugin
8899
description: Manage Claude Code plugins
100+
- name: reload-plugins
101+
description: Reload all active plugins to apply pending changes without restarting
89102
- name: pr-comments
90-
description: View pull request comments
103+
description: Fetch and display comments from a GitHub pull request (auto-detects PR for current branch, requires gh CLI)
91104
- name: privacy-settings
92105
description: View and update your privacy settings
93106
- name: remote-env
@@ -103,12 +116,12 @@ commands:
103116
description: Rename the current session (without a name, generates one from conversation history)
104117
argument-hint: "[name]"
105118
- name: resume
106-
description: "Resume a conversation by ID or name, or open the session picker"
119+
description: "Resume a conversation by ID or name, or open the session picker. Alias: /continue"
107120
argument-hint: "[session]"
108121
- name: review
109-
description: Request code review
122+
description: Review a pull request for code quality, correctness, security, and test coverage (requires gh CLI)
110123
- name: rewind
111-
description: Rewind the conversation and/or code, or summarize from a selected message
124+
description: "Rewind the conversation and/or code to a previous point, or summarize from a selected message. Alias: /checkpoint"
112125
- name: sandbox
113126
description: "Enable sandboxed bash tool with filesystem and network isolation for safer, more autonomous execution"
114127
- name: security-review
@@ -131,7 +144,7 @@ commands:
131144
description: Resume a remote session from claude.ai (subscribers only)
132145
argument-hint: "[session]"
133146
- name: terminal-setup
134-
description: Install Shift+Enter key binding for newlines (iTerm2 and VSCode only)
147+
description: Configure terminal keybindings for Shift+Enter and other shortcuts (VS Code, Alacritty, Warp)
135148
- name: theme
136149
description: Change the color theme
137150
- name: todos
@@ -141,4 +154,4 @@ commands:
141154
- name: upgrade
142155
description: Upgrade to Max for higher rate limits and more Opus
143156
- name: vim
144-
description: Enter vim mode for alternating insert and command modes
157+
description: Toggle between Vim and Normal editing modes

assets/built-in-commands/codex.yml

Lines changed: 33 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -12,28 +12,38 @@ commands:
1212
- name: agent
1313
description: Switch the active agent thread
1414
- name: approvals
15-
description: Set what Codex can do without asking first
15+
description: Choose what Codex is allowed to do
1616
- name: apps
17-
description: Browse apps (connectors) and insert them into your prompt
17+
description: Manage apps
18+
- name: clean
19+
description: Stop all background terminals
20+
- name: clear
21+
description: Clear the terminal and start a new chat
22+
- name: collab
23+
description: Change collaboration mode (experimental)
1824
- name: compact
19-
description: Summarize the visible conversation to free tokens
25+
description: Summarize conversation to prevent hitting the context limit
26+
- name: copy
27+
description: Copy the latest Codex output to your clipboard
2028
- name: diff
2129
description: Show the Git diff, including files Git isn't tracking yet
2230
- name: elevate-sandbox
23-
description: Upgrade to elevated sandbox mode for enhanced permissions
31+
description: Set up elevated agent sandbox
2432
- name: debug-config
25-
description: Print config layer and requirements diagnostics
33+
description: Show config layers and requirement sources for debugging
2634
- name: exit
2735
description: Exit the CLI (alias for /quit)
2836
- name: experimental
2937
description: Toggle experimental features
38+
- name: fast
39+
description: Toggle Fast mode for fastest inference at 2X plan usage
3040
- name: feedback
3141
description: Send logs to the Codex maintainers
3242
- name: fork
33-
description: Fork the current conversation into a new thread
43+
description: Fork the current chat
3444
argument-hint: "[session]"
3545
- name: init
36-
description: Generate an AGENTS.md scaffold in the current directory
46+
description: Create an AGENTS.md file with instructions for Codex
3747
- name: logout
3848
description: Sign out of Codex
3949
- name: mcp
@@ -42,30 +52,39 @@ commands:
4252
description: Attach a file to the conversation
4353
argument-hint: "<path>"
4454
- name: model
45-
description: Choose the active model (and reasoning effort, when available)
55+
description: Choose what model and reasoning effort to use
4656
- name: new
47-
description: Start a new conversation inside the same CLI session
57+
description: Start a new chat during a conversation
4858
- name: permissions
49-
description: Set what Codex can do without asking first
59+
description: Choose what Codex is allowed to do
5060
- name: personality
5161
description: Choose a communication style for responses
5262
- name: plan
5363
description: Switch to plan mode and optionally send a prompt
5464
- name: ps
55-
description: Show experimental background terminals and their recent output
65+
description: List background terminals
5666
- name: quit
5767
description: Exit the CLI
68+
- name: realtime
69+
description: Toggle realtime voice mode (experimental)
70+
- name: rename
71+
description: Rename the current thread
72+
argument-hint: "[name]"
5873
- name: resume
5974
description: Resume a saved conversation from your session list
6075
- name: review
61-
description: Ask Codex to review your working tree
76+
description: Review current changes and find issues
77+
- name: settings
78+
description: Configure realtime microphone/speaker
6279
- name: skills
63-
description: Browse and insert skills (experimental)
80+
description: Use skills to improve how Codex performs specific tasks
6481
- name: status
65-
description: Display session configuration and token usage
82+
description: Show current session configuration and token usage
6683
- name: sandbox-add-read-dir
6784
description: Grant sandbox read access to an extra directory (Windows only)
6885
- name: statusline
6986
description: Configure TUI status-line fields interactively
87+
- name: theme
88+
description: Choose a syntax highlighting theme
7089
- name: undo
7190
description: Revert Codex's most recent turn

assets/built-in-commands/gemini.yml

Lines changed: 32 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@ commands:
1717
description: File an issue about Gemini CLI
1818
argument-hint: "[headline]"
1919
- name: chat
20-
description: Manage conversation history with sub-commands for saving, resuming, listing, deleting, and sharing chats
20+
description: Manage conversation history with sub-commands for saving, resuming, listing, deleting, sharing, and debugging chats
21+
- name: commands
22+
description: Manage custom slash commands loaded from .toml files
2123
- name: clear
2224
description: Clear the terminal screen including session history and scrollback
2325
- name: compress
@@ -28,22 +30,38 @@ commands:
2830
description: Manage workspace directories for multi-directory support
2931
- name: dir
3032
description: Alias for /directory
33+
- name: docs
34+
description: Open the Gemini CLI documentation in your browser
3135
- name: editor
3236
description: Open a dialog for selecting supported editors
3337
- name: exit
3438
description: Exit Gemini CLI
3539
- name: extensions
36-
description: List all active extensions in the current session
40+
description: "Manage extensions: install, enable, disable, explore, config, update, and more"
3741
- name: help
3842
description: Display help information about Gemini CLI and available commands
43+
- name: hooks
44+
description: "Manage hooks for intercepting and customizing behavior at lifecycle events"
45+
argument-hint: "[disable-all|disable|enable-all|enable|list]"
46+
- name: ide
47+
description: "Manage IDE integration"
48+
argument-hint: "[disable|enable|install|status]"
3949
- name: init
4050
description: Generate a tailored GEMINI.md context file for your project
4151
- name: mcp
42-
description: List MCP servers, their status, and available tools
52+
description: "Manage MCP servers: list, auth, disable, enable, refresh"
4353
- name: memory
44-
description: Manage AI instructional context loaded from GEMINI.md files
54+
description: Manage hierarchical instructional context loaded from GEMINI.md files
4555
- name: model
46-
description: Open model selection dialog
56+
description: "Open model selection dialog or set model directly"
57+
argument-hint: "[manage|set <model-name>]"
58+
- name: permissions
59+
description: Manage folder trust settings and other permissions
60+
argument-hint: "[trust <directory-path>]"
61+
- name: plan
62+
description: Switch to Plan Mode (read-only) and view the current plan
63+
- name: policies
64+
description: "Manage policies: list all active policies grouped by mode"
4765
- name: privacy
4866
description: Display the Privacy Notice and data collection preferences
4967
- name: quit
@@ -54,14 +72,21 @@ commands:
5472
description: Resume a previous conversation session
5573
argument-hint: "[session]"
5674
- name: rewind
57-
description: Browse and rewind conversation history and file changes
75+
description: Browse and rewind conversation history and file changes (Esc x2 shortcut)
5876
- name: settings
5977
description: Open the settings editor to view and modify settings
78+
- name: setup-github
79+
description: Set up GitHub Actions to triage issues and review PRs with Gemini
80+
- name: shells
81+
description: "Toggle background shells view and manage long-running processes. Alias: /bashes"
6082
- name: skills
6183
description: Manage Agent Skills for specialized workflows
6284
argument-hint: "[list|enable|disable|refresh]"
6385
- name: stats
64-
description: Display session statistics including token usage and duration
86+
description: "Display session statistics: session info, model tokens/quota, or per-tool stats"
87+
argument-hint: "[session|model|tools]"
88+
- name: terminal-setup
89+
description: Configure terminal keybindings for multiline input (VS Code, Cursor, Windsurf)
6590
- name: theme
6691
description: Open a dialog to change the visual theme
6792
- name: tools

0 commit comments

Comments
 (0)