repo: add .gitignore file

Unfortunately git doesn't support regexps in ignore files. Add .gitignore file
which is roughly equivalent to mercurial's ignore file.