To clarify a little what others said, there are clear three categories of things that are excluded, and git uses different exception files for each category:
, , , β *.o, , , .
.gitignore ( ). , , , , .gitignore git add .
, , , , . , Emacs, , Foo.~1~, git checkouts
"" , - ~/.gitignore; git, , , :
git config --global core.excludesfile ~/.gitignore
[ , .]
, Emacs *~ ~/.gitignore.
, "" , , , .
.git/info/exclude. .git, status ( ).
Git , , .