From d0912401157fce54544cf3f9b8620659f1ac0335 Mon Sep 17 00:00:00 2001 From: Jarmo Isotalo Date: Sat, 29 Oct 2016 00:31:56 +0300 Subject: [PATCH] If `package.json` or `Dockerfile` is present, assume it's static (#100) deployment --- bin/now-deploy.js | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/bin/now-deploy.js b/bin/now-deploy.js index fb1c262..c005389 100755 --- a/bin/now-deploy.js +++ b/bin/now-deploy.js @@ -231,7 +231,7 @@ async function sync(token) { hasPackage = true } - [hasPackage, hasDockerfile, isStatic] = await Promise.all([ + [hasPackage, hasDockerfile] = await Promise.all([ await (async () => { try { await stat(resolve(path, 'package.json')) @@ -247,14 +247,6 @@ async function sync(token) { return false } return true - })(), - await (async () => { - try { - await stat(resolve(path, 'index.html')) - } catch (err) { - return false - } - return true })() ]) @@ -290,10 +282,6 @@ async function sync(token) { } deploymentType = 'docker' - } else if (isStatic) { - if (debug) { - console.log('[debug] `index.html` found, assuming static deployment') - } } else { if (debug) { console.log('[debug] No manifest files found, assuming static deployment')