fix #4 but not remote-host stuff yet