removed troublesome panic
removed panic() invocation to use error logging instead
updated logging to syslog
added default for $HOME