Reputation: 328
If you see the image two .cs files are locked and i just added Test.cs file in project and it is started showing as ignored file. Is there any way to make all newly added files automatically added to source control?.
Upvotes: 5
Views: 4270
Reputation: 1288
Right-click on the file Select Git => Add Ignored file to source control
Upvotes: 2
Reputation: 537
Right click on the file in question > Under the Exclude From Project, select the option "Add ignored file to Source Control"
Upvotes: 4
Reputation: 1323803
The "red minus overlay icon in Visual studio's Solution Explorer?" should means "excluded from build", not "ignored by Git".
Double-check in command-line with:
cd /path/to/project
git check-ignore -v -- Test.cs
If it is also ignored, that check-ignore command will give you the exact .gitignore
and rule.
Upvotes: 3