auto download latest version
fix a few bugs