Paste drops $' sequence from clipboard content

Resolved 💬 2 comments Opened Mar 10, 2026 by companygardener Closed Mar 10, 2026

Bug description

When pasting text that contains the character sequence $' (dollar sign followed by single quote), that sequence is silently dropped from the pasted content.

Reproduction

  1. Copy the following SQL DDL to clipboard (e.g. from a text editor or terminal):
routing_number ~ '^\d{9}$') UNIQUE
  1. Paste it into Claude Code's input
  1. The pasted text becomes:
routing_number ~ '^\d{9}) UNIQUE

The $' before the closing paren is stripped.

Expected behavior

The full text including $' should be preserved on paste.

Notes

  • This affects any content containing $' — regex patterns in SQL CHECK constraints are a common case
  • $' is a special variable in some shell contexts (ANSI-C quoting in bash), which may be related to the stripping

Environment

  • macOS (Darwin 24.6.0)
  • Claude Code CLI

View original on GitHub ↗

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