Skip to content

Search & Replace exclude deleted files by default #164929

@rosyatrandom

Description

@rosyatrandom

Problem:

  • Branch A has a file F that is not in branch B
  • Switch from B to A with F open in an editor
  • F is marked as 'deleted' by VS Code, and is in neither tracked or untracked files
  • Perform a Search & Replace that matches text in F
  • VS Code includes F in the list of matches
  • Replacing all and saving (a 2-click action) saves F and adds it to untracked files

This means you can easily accidentally add F to branch B if you're not paying attention

Solution:

Search & Replace should exclude deleted files by default, so they do not appear in the list of matches

Metadata

Metadata

Assignees

Labels

bugIssue identified by VS Code Team member as probable bugconfirmedIssue has been confirmed by VS Code Team membersearchSearch widget and operation issues

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions