fix #2 and integrate native system for switch the version in the code
fix #3