small bug fixes and addition of .gitignore