Update script with flags