Added conditional execution of some code for aquaemacs only.
Set username to env USER
Created new-shell function with improved logic