added some comments and cleaned up for easier reading
also added newline character to rsync.sh, sending password for pi should work now