How to define in gitignore to ignore all except one file extension?
So I just want to track one file extensions.
I try something like this -> !*.sql
but this not working.
Read here: https://git-scm.com/docs/gitignore
"An optional prefix "!" which negates the pattern; any matching file excluded by a previous pattern will become included again"
As said, you have to exclude everything first (with pattern '*') , then include some patterns again (your desired '!*.sql').
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.