[Bug] macOS project folders with leading hyphen break terminal navigation

Resolved 💬 3 comments Opened Apr 9, 2026 by rnsc Closed May 22, 2026

Bug Description
On macOS, Claude code saves projects with a leading "-" which makes it very hard to navigate inside the folder when using a terminal with Bash, and escaping or quoting doesn't work.
On macOS, for example, everything is stored under "/Users/username/...", which translates to a project folder named "-Users-username-...", and if you try to use the command "cd", you end up with the following error "bash: cd: -U: invalid option". Escaping with backslashes doesn't work nor quoting.
It would be nice if Claude named those folders differently, with something like "_" instead "-".

While I understand there are other ways to cd by addin a leading "./" or switch to zsh, but it'd be nice if either, this could be customised, or the default behaviour would be different to avoid this scenario.
Thank you for considering my feedback.

Environment Info

  • Platform: darwin
  • Terminal: iTerm.app
  • Version: 2.1.97
  • Feedback ID: 4a787872-9d28-4f95-b0ea-695178ba63eb

Errors

[]

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗