Rebuild gen.sh to wget