Reputation: 36311
I have the following .gitignore
file, and whenever I do git add .
only the .gitignore
file gets added to the repo, what is wrong with my ignore file?
Here is the file:
# Ignore Everything
*
# Except for these:
!.gitignore
!Assets/
!ProjectSettings/
Upvotes: 1
Views: 1265
Reputation: 36860
The wildcard without a leading slash is excluding everything within all directories.
Here's the sample code that the gitignore documentation suggests (modified for your case)
# exclude everything
/*
!/Assets
!/ProjectSettings
Here's the documentation site: http://git-scm.com/docs/gitignore
Upvotes: 5