|
|
|
|
|
by firasd
7 hours ago
|
|
What did you test exactly? Look what I’m asking for is not complicated Node cutpaste.js inputpath startcharnum endcharnum outputpath startcharnum I was just using it as an example of how dropping claude / gpt in a Linux shell and saying good luck and then giving interviews about spawning sub agents seems to overlook basic text editing primitives But if you managed to move an arbitrary char range from one file to another using Claude Code talking to the TS LSP server let me know that would be enlightening. |
|
Still, these links may be of interest:
TypeScript’s language-service implementation of the “Move to file” refactor: https://github.com/microsoft/TypeScript/blob/main/src/servic...
Documentation for how `typescript-language-server` exposes that refactor as an opt-in code action: https://github.com/typescript-language-server/typescript-lan...
`ast-grep`, an AST-based search and transformation tool that may be closer in spirit to the cli functionality you describe, albeit more general-purpose: https://github.com/ast-grep/ast-grep