Updated generate.sh