duplicated method generateGit

This would cause the first method will not be executed. Thus change the latter to correct name to ensure all intended steps are done.