Cursor goto CLI command does not escape characters

Where does the bug appear (feature/product)?

Cursor CLI

Describe the Bug

There is a cursor CLI command -g or --goto that takes a filename:line:column argument.

If you have provide a filename path that has a parenthesis ( ) it will give an error like this

/home/joshh/.cursor-server/bin/63fcac100bd5d5749f2a98aa47d65f6eca61db30/bin/remote-cli/cursor: 1: eval: Syntax error: “(” unexpected

These paths are often used in sveltekit for layout groups

I found I can work around it by escaping the path myself and then double quoting it.

cursor -g “src/routes/(auth)/+layout.server.ts”

For sveltekit inspector to work I had to jump through a number of hoops such as creating a launch script. It would be better if cursor would take the unescaped path and make it work.

Steps to Reproduce

Try launching with cursor -g "src/routes/\(auth\)/+layout.server.ts"

Operating System

Linux

Current Cursor Version (Menu → About Cursor → Copy)

Version: 2.0.69 (user setup)
VSCode Version: 1.99.3
Commit: 63fcac100bd5d5749f2a98aa47d65f6eca61db30
Date: 2025-11-07T18:21:29.650Z
Electron: 37.7.0
Chromium: 138.0.7204.251
Node.js: 22.20.0
V8: 13.8.258.32-electron.0
OS: Windows_NT x64 10.0.26200

Does this stop you from using Cursor

No - Cursor works, but with this issue

Hey, thanks for the report. This is definitely a CLI issue where the -g/--goto command isn’t correctly escaping special characters in file paths.

The error message confirms there’s an eval syntax error in the remote-cli script. Your workaround of manually escaping the parentheses is correct, but the CLI should definitely handle this automatically.

I’ll pass this on to the team. For better integration with tools like SvelteKit Inspector, the CLI should accept unescaped paths and handle the escaping internally.

Let me know if you find any other special characters that cause similar problems.

This topic was automatically closed 22 days after the last reply. New replies are no longer allowed.