update build script to support github