Reputation: 14816
I'm working on a branch rewriting some code in VSCode. (I have the plugin GitLens installed.) I'm rewriting this one function - let's call it foo
- and I'm trying to understand where it has been used before.
Is there a way to search for something in the modified / deleted changes in Git using VSCode? I mean like pressing cmd + shift + f
and then typing the word so you get highlights in all current git changes?
Upvotes: 13
Views: 5178
Reputation: 11
If you have the gitlens extension, you can use the command pallette (Ctrl/Cmd + Shift + p) and search for 'Search commits'. This should show an input for you to search for commits by message, hash, etc.
Upvotes: 1
Reputation: 4622
In gitlens left bottom you can see "SEARCH COMMITS" there you can search in change or commit messages
here is example result when I search class in mvn project
When I search a function name it also finds
Upvotes: 13