Use `raise-user-error` instead of `error`

Thanks Robby!
Improve error handling

Make more error cases print the current directory so
that the shell script doesn't `cd` somewhere else