Git: Ignore & Stop Tracking
VS CodeUntrack a committed file and add it to .gitignore in one click.
Adds an “Ignore & Untrack” action to the Source Control context menu that removes the selected file(s) from the git index and writes an anchored .gitignore entry — the fix for “I committed a file I shouldn’t have.”