claude-code - 💡(How to fix) Fix [BUG] # shortcut does not write to CLAUDE.md [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#54747Fetched 2026-04-30 06:37:08
View on GitHub
Comments
0
Participants
1
Timeline
4
Reactions
0
Author
Participants
Timeline (top)
labeled ×4

Error Message

Error Messages/Logs

  • No error or confirmation message is shown when using #, making the failure silent

Fix Action

Fix / Workaround

Workaround: Manually editing via /memory (opens file in nano) works correctly.

RAW_BUFFERClick to expand / collapse

Preflight Checklist

  • I have searched existing issues and this hasn't been reported yet
  • This is a single bug report (please file separate reports for different bugs)
  • I am using the latest version of Claude Code

What's Wrong?

Environment:

  • OS: macOS 14 (Darwin 24.6.0)
  • Claude Code version: (run claude --version to get this)

Description:
The # shortcut (typing # text as a message) is supposed to append text directly to ~/.claude/CLAUDE.md. Instead, the message is sent to Claude normally but nothing is
written to CLAUDE.md.

Steps to reproduce:

  1. Open Claude Code
  2. Type # some text to remember and send
  3. Check ~/.claude/CLAUDE.md

Expected behavior: some text to remember is appended to ~/.claude/CLAUDE.md

Actual behavior: CLAUDE.md is unchanged. The message is received by Claude as a regular chat message.

Workaround: Manually editing via /memory (opens file in nano) works correctly.

What Should Happen?

some text to remember is appended to ~/.claude/CLAUDE.md

Error Messages/Logs

Steps to Reproduce

⏺ Here are the steps to fill in:


  1. Open Claude Code in any directory
  2. Type # some text to remember as a message and press Enter
  3. After Claude responds, run /memory — it opens ~/.claude/CLAUDE.md in nano
  4. Observe that the text from step 2 was not appended to the file
  5. Exit nano (Ctrl+X)

Additional context:

  • The message IS received by Claude as a normal chat message
  • Manually editing via /memory works correctly
  • File permissions on ~/.claude/CLAUDE.md are correct (-rw-r--r--, owned by user)
  • No error or confirmation message is shown when using #, making the failure silent

Paste that into the "Steps to Reproduce" field.

Claude Model

None

Is this a regression?

No, this never worked

Last Working Version

No response

Claude Code Version

 2.1.123 (Claude Code)

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Warp

Additional Information

No response

extent analysis

TL;DR

The issue can be mitigated by manually editing the ~/.claude/CLAUDE.md file using the /memory command, which works correctly.

Guidance

  • Verify that the file permissions on ~/.claude/CLAUDE.md are correct and the file is owned by the user, as mentioned in the issue.
  • Check if there are any differences in behavior when using the # shortcut in different directories or contexts.
  • Investigate if there are any configuration options or settings in Claude Code that could be affecting the behavior of the # shortcut.
  • Consider reporting this issue to the developers of Claude Code, as it is mentioned that this feature never worked.

Notes

The issue seems to be specific to the # shortcut in Claude Code, and the fact that it never worked suggests that it might be a bug or an unimplemented feature.

Recommendation

Apply workaround: Manually editing the ~/.claude/CLAUDE.md file using the /memory command is a reliable alternative until the issue is resolved.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING