Checking if repository before pushing

Avoids an error in git push