diff --git a/dist/index.js b/dist/index.js index 70f4fc5..deb3498 100644 --- a/dist/index.js +++ b/dist/index.js @@ -195,8 +195,10 @@ try { // Load key into agent console.log('Load key'); //let sshAdd = child_process.execSync(`echo "${token}" | ssh-add "${keyFile}"`, { stdio: 'inherit' }); + var sshAdd; + try { - let sshAdd = child_process.execSync(`ssh-add ${keyFile}`, { stdio: 'inherit', env: { 'SSH_ASKPASS': `${homeSsh}/askpass` } }); + let sshAdd = child_process.execSync(`ssh-add ${keyFile}`, { stdio: 'inherit', env: { 'SSH_ASKPASS': `${homeSsh}/askpass` } }); } catch (exception) { console.log(sshAdd); console.log(exception); diff --git a/index.js b/index.js index afaf67c..8bbe2e8 100644 --- a/index.js +++ b/index.js @@ -78,8 +78,10 @@ try { // Load key into agent console.log('Load key'); //let sshAdd = child_process.execSync(`echo "${token}" | ssh-add "${keyFile}"`, { stdio: 'inherit' }); + var sshAdd; + try { - let sshAdd = child_process.execSync(`ssh-add ${keyFile}`, { stdio: 'inherit', env: { 'SSH_ASKPASS': `${homeSsh}/askpass` } }); + let sshAdd = child_process.execSync(`ssh-add ${keyFile}`, { stdio: 'inherit', env: { 'SSH_ASKPASS': `${homeSsh}/askpass` } }); } catch (exception) { console.log(sshAdd); console.log(exception);