[BUG] --cwd and -c do not work

Resolved 💬 4 comments Opened Mar 15, 2025 by maxmcd Closed Mar 17, 2025

Environment

  • Platform (select one):
  • [x] Anthropic API
  • [ ] AWS Bedrock
  • [ ] Google Vertex AI
  • [ ] Other: <!-- specify -->
  • Claude CLI version: 0.2.45
  • Operating System: debian linux and macos
  • Terminal: iterm2 and xterm.js

Bug Description

The --cwd and -c commands have no effect.

Steps to Reproduce

  1. claude --cwd ./foo or claude --cwd /Users/maxm/foo or claude --c=foo, etc
  2. See claude running with cwd set to the current directory
  3. Slight feeling of confusion

Expected Behavior

That --cwd will set the cwd.

Actual Behavior

It does not

Additional Context

Hey hopefully I am doing something wrong here because this seems broken at least back to 0.2.19, but I tried everything I could.

View original on GitHub ↗

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