/clear command resets working directory to home directory
Resolved 💬 2 comments Opened Jan 17, 2026 by victorysightsound Closed Feb 28, 2026
Description
The /clear command resets the working directory to the user's home directory instead of preserving the current working directory.
Expected Behavior
After running /clear, the working directory should remain unchanged. If I was in ~/projects/pirdly-research before clearing, I should still be there after clearing.
Actual Behavior
After running /clear, the working directory is reset to the home directory (~ or /Users/<username>).
Reproduction Steps
- Start Claude Code
- Navigate to a project directory (e.g.,
cd ~/projects/pirdly-research) - Confirm current directory with
pwd - Run
/clearto clear the conversation - Run
pwdagain
Result: Working directory is now the home directory instead of the project directory.
Environment
- OS: macOS (Darwin 25.2.0)
- Date observed: 2026-01-17
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗