# project_panel: Fix duplicating a file only selects the copy suffix \(\#53146\) · gitcafe/zed

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

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

Visibility: public

Requested revision: ae4404f148b6b8e9dab4f1d9dd9366bc135c37a7

Requested commit: ae4404f148b6b8e9dab4f1d9dd9366bc135c37a7

Commit: ae4404f148b6b8e9dab4f1d9dd9366bc135c37a7

Tree: 39d1835656df85f2c5f469a46c7e9d269927fff7

Author: Om Chillure

Committer: GitHub

## Message

```
project_panel: Fix duplicating a file only selects the copy suffix (#53146)

Self-Review Checklist:

- [x] I've reviewed my own diff for quality, security, and reliability
- [ ] 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)
- [x] Tests cover the new/changed behavior
- [x] Performance impact has been considered and is acceptable

Closes #53116

Video 

[Screencast from 2026-04-04
19-14-55.webm](https://github.com/user-attachments/assets/d17945d6-b17c-435d-8155-648cd7ba574b)


Release Notes:

- Fixed: File duplication rename now selects the entire filename stem
instead of just the " copy" suffix, allowing users to type a new name
without manually clearing text

---------

Co-authored-by: Smit Barmase <heysmitbarmase@gmail.com>
```

## Parents

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

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