Merge pull request #267 from trheyi/main

[fix] setup if the app.json exist ignore
This commit is contained in:
Max 2022-11-17 14:42:27 +08:00 committed by GitHub
commit 489886a381
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -230,6 +230,13 @@ func makeDirs(root string) error {
func makeInit(root string) error {
files := data.AssetNames()
// if the app.json exist ignore
file := filepath.Join("app.json")
if _, err := os.Stat(filepath.Join(root, file)); err == nil { // exists
return nil
}
for _, file := range files {
if strings.HasPrefix(file, "init/") {
dst := filepath.Join(root, strings.TrimPrefix(file, "init/"))