diff --git a/lib/utils/template_generator.js b/lib/utils/template_generator.js index cb36b3b8..7cef7ca4 100644 --- a/lib/utils/template_generator.js +++ b/lib/utils/template_generator.js @@ -107,10 +107,8 @@ class TemplateGenerator { utils.sed('package.json', '%APP_NAME%', name); if (fs.existsSync('dot.gitignore')) { fs.moveSync('dot.gitignore', '.gitignore'); - } - - if (fs.existsSync('dot.gitignore')) { - fs.moveSync('dot.gitignore', '.gitignore'); + } else if (!fs.existsSync('.gitignore')) { + fs.copySync(fs.embarkPath('templates/dot.gitignore'), '.gitignore'); } if (installPackages) { diff --git a/templates/demo/dot.gitignore b/templates/demo/dot.gitignore deleted file mode 100644 index 64186267..00000000 --- a/templates/demo/dot.gitignore +++ /dev/null @@ -1,6 +0,0 @@ -.embark -config/production/password -config/livenet/password -coverage -dist -node_modules diff --git a/templates/boilerplate/dot.gitignore b/templates/dot.gitignore similarity index 87% rename from templates/boilerplate/dot.gitignore rename to templates/dot.gitignore index 64186267..72a305ed 100644 --- a/templates/boilerplate/dot.gitignore +++ b/templates/dot.gitignore @@ -1,4 +1,5 @@ .embark +chains.json config/production/password config/livenet/password coverage diff --git a/templates/simple/dot.gitignore b/templates/simple/dot.gitignore deleted file mode 100644 index 64186267..00000000 --- a/templates/simple/dot.gitignore +++ /dev/null @@ -1,6 +0,0 @@ -.embark -config/production/password -config/livenet/password -coverage -dist -node_modules