Fixed crash if .gitconfig missing/user not set

The generator was crashing while trying to get the default answers if the file `.gitconfig` wasn't present or lacking the `user.name` setting, which I fixed. When running under Windows it wasn't picking up any of the user's home directory or username either, so I changed it to get those correctly.