make sure we check for write access before starting the install, and add correct exit code
4 files changed