From d47d03c9800b13aa549899299f3b6b71e0f4417f Mon Sep 17 00:00:00 2001 From: AJ ONeal Date: Tue, 5 Nov 2019 03:18:48 -0700 Subject: [PATCH] update templates --- bin/init.js | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) diff --git a/bin/init.js b/bin/init.js index 9cdd2ba..454b6cb 100644 --- a/bin/init.js +++ b/bin/init.js @@ -83,12 +83,6 @@ function writeGreenlockJs(pkgdir, flags) { // continue } - if (flags.cluster) { - tmpl = tmpl.replace( - /options.cluster = false/g, - 'options.cluster = true' - ); - } if (flags.maintainerEmail) { tmpl = tmpl.replace( /pkg.author/g, @@ -117,17 +111,9 @@ function writeServerJs(pkgdir, flags) { } if (flags.cluster) { - tmpl = tmpl.replace( - /options.cluster = false/g, - 'options.cluster = true' - ); - } - if (flags.maintainerEmail) { - tmpl = tmpl.replace( - /pkg.author/g, - JSON.stringify(flags.maintainerEmail) - ); + tmpl = tmpl.replace(/cluster: false/g, 'cluster: true'); } + fs.writeFileSync(path.join(pkgdir, serverJs), tmpl); console.info("created '%s'", serverJs); }