fix: remove the .git directory in the template (#1929)

fixed: https://github.com/wailsapp/wails/issues/1928
This commit is contained in:
Misite Bao 2022-10-02 18:03:11 +08:00 committed by GitHub
commit ef32ea2575
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -189,6 +189,12 @@ func initProject(options *templates.Options, quiet bool, ciMode bool) error {
updateReplaceLine(workspace)
}
// Remove the `.git`` directory in the template project
err = os.RemoveAll(".git")
if err != nil {
return err
}
if options.InitGit {
err = initGit(options)
if err != nil {