diff --git a/scripts/unicorn.js b/scripts/unicorn.js index 75a7935c4b..ba79321f02 100644 --- a/scripts/unicorn.js +++ b/scripts/unicorn.js @@ -38,9 +38,9 @@ module.exports = function (callback, options) { var url = siteHostName + "/unicorn.aspx"; - var syncScript =__dirname + "/Unicorn/./Sync.ps1 -secret " + secret + " -url " + url; + var syncScript = `"./Sync.ps1" -secret ${secret} -url "${url}"`; var options = { cwd: __dirname + "/Unicorn/", maxBuffer: 1024 * 500 }; - var process = exec("powershell -executionpolicy unrestricted \"" + syncScript + "\"", options, function (err, stdout, stderr) { + var process = exec(`powershell -executionpolicy unrestricted ${syncScript}`, options, function (err, stdout, stderr) { if (err !== null) throw err; console.log(stdout); callback();