# terminal_view: Use backslash escaping for dropped file paths for mac \(\#57747\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/7e0f63412c60008f9dae7fcf65fc6ab6d7e0f957)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: 7e0f63412c60008f9dae7fcf65fc6ab6d7e0f957

Requested commit: 7e0f63412c60008f9dae7fcf65fc6ab6d7e0f957

Commit: 7e0f63412c60008f9dae7fcf65fc6ab6d7e0f957

Tree: 3558b12dc92434da607a552aed8b17d8ff3f626d

Author: mertkanakkoc

Committer: GitHub

## Message

```
terminal_view: Use backslash escaping for dropped file paths for mac (#57747)

Self-Review Checklist:

- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [ ] Tests cover the new/changed behavior
- [ ] Performance impact has been considered and is acceptable

When files are dragged into the terminal, paths were formatted using
Rust's Debug format (`{path:?}`), which wraps them in double quotes.
This caused issues with programs like Claude Code that parse bare paths
from terminal input — quoted paths were treated as plain text instead of
file references.

This change replaces double-quote wrapping with backslash escaping for
special shell characters on Unix, which is both valid shell syntax and
compatible with path-parsing tools running in the terminal. On non-Unix
platforms the previous behavior is preserved.

Tested on macOS only. Unable to verify Windows behavior.

Fixes #57471

Release Notes:

- Fixed/ file drag-and-drop into terminal inserting double-quoted paths,
which prevented tools like Claude Code from recognizing them as file
references.

---------

Co-authored-by: Conrad Irwin <conrad.irwin@gmail.com>
Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
```

## Parents

- [35c3d272828328b7217efccc146dc5b7d53490ff](https://git.cafe/gitcafe/zed/commit/35c3d272828328b7217efccc146dc5b7d53490ff?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/7e0f63412c60008f9dae7fcf65fc6ab6d7e0f957?format=markdown)
