Added repo check after saving gitignore