Bugfix in IdGenerator. Also modify .gitignore.