Stop shell scripts if there's an error

Eliminates this fun issue that's bitten a few of us:

```
cd /does/not/exist/rt/dir
git reset --hard HEAD
echo "fml"
```