Initial commit of working code
Tweaks to get remote and local aligned