claude-code icon indicating copy to clipboard operation
claude-code copied to clipboard

[Feature Request] Allow custom slash commands access the selected lines in the IDE

Open rse opened this issue 3 months ago • 4 comments

With /ide active, Claude Code has access to the selected lines within the IDE. This is great for running actions on a narrow scope. Unfortunately, custom slash commands do not have access to the selected lines as it looks. Please provide something like $SELECTION inside custom slash commands so that one can e.g. create an elaborated "/explain" command which not just can be used like "/explain @file" or "/explain whatever else", but also just as "/explain" and then it would pick up the selected lines. For this it internally just references $ARGUMENTS $SELECTION for its context.

rse avatar Aug 31 '25 08:08 rse