Generate script with user template