gallery build script working