From 3983ff9306db43ce75821da06bcd5e0e18af43c6 Mon Sep 17 00:00:00 2001 From: Barry Gitarts Date: Tue, 14 Jan 2020 11:22:44 -0500 Subject: [PATCH] add option to use HTTPS for gh-pages --- scripts/deploy.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/scripts/deploy.js b/scripts/deploy.js index 66248c5..eefc33e 100755 --- a/scripts/deploy.js +++ b/scripts/deploy.js @@ -5,11 +5,16 @@ const ghpublish = promisify(publish) /* fix for "Unhandled promise rejections" */ process.on('unhandledRejection', err => { throw err }) +const Args = process.argv.slice(2) +const USE_HTTPS = Args[0] && Args[0].toUpperCase() === 'HTTPS' + const branch = 'gh-pages' const org = 'status-im' const repo = 'liquid-funding' /* use SSH auth by default */ -const repoUrl = `git@github.com:${org}/${repo}.git` +const repoUrl = USE_HTTPS + ? `https://github.com/${org}/${repo}.git` + : `git@github.com:${org}/${repo}.git` /* alternative auth using GitHub user and API token */ if (process.env.GH_USER != undefined) {