mirror of
https://github.com/webfactory/ssh-agent.git
synced 2024-12-28 01:40:37 +00:00
Avoid using a separate shell
This commit is contained in:
parent
f03f6e3358
commit
2bcaae34da
3 changed files with 3 additions and 9 deletions
6
.github/workflows/demo.yml
vendored
6
.github/workflows/demo.yml
vendored
|
@ -59,10 +59,10 @@ jobs:
|
|||
${{ secrets.MPDUDE_TEST_2_DEPLOY_KEY }}
|
||||
- run: |
|
||||
ssh-add -l
|
||||
cat ~/.ssh/config
|
||||
ls -alh ~/.ssh
|
||||
git clone git@github.com:mpdude/test-2.git test-2-git
|
||||
|
||||
# cat ~/.ssh/config
|
||||
# ls -alh ~/.ssh
|
||||
# git clone https://github.com/mpdude/test-1.git test-1-http
|
||||
# git clone git@github.com:mpdude/test-1.git test-1-git
|
||||
# git clone ssh://git@github.com/mpdude/test-1.git test-1-git-ssh
|
||||
|
@ -76,4 +76,4 @@ jobs:
|
|||
# echo "secret-passphrase" | ssh-add ~/.ssh/5965bf89ab6e2900262e3f6802dfb4d65cb0de539d0fbb97d381e7130a4ba7e9
|
||||
# ssh-add -L
|
||||
# git clone git@github.com:mpdude/test-2.git test-2-git
|
||||
shell: bash
|
||||
# shell: bash
|
||||
|
|
3
dist/index.js
vendored
3
dist/index.js
vendored
|
@ -166,12 +166,9 @@ try {
|
|||
const matches = /^(SSH_AUTH_SOCK|SSH_AGENT_PID)=(.*); export \1/.exec(lines[lineNumber])
|
||||
if (matches && matches.length > 0) {
|
||||
core.exportVariable(matches[1], matches[2])
|
||||
process.env[matches[1]] = matches[2]; // use variables for ssh-add below
|
||||
}
|
||||
}
|
||||
|
||||
console.log(process.env);
|
||||
|
||||
console.log("Adding private keys to agent");
|
||||
var keyNumber = 0;
|
||||
|
||||
|
|
3
index.js
3
index.js
|
@ -49,12 +49,9 @@ try {
|
|||
const matches = /^(SSH_AUTH_SOCK|SSH_AGENT_PID)=(.*); export \1/.exec(lines[lineNumber])
|
||||
if (matches && matches.length > 0) {
|
||||
core.exportVariable(matches[1], matches[2])
|
||||
process.env[matches[1]] = matches[2]; // use variables for ssh-add below
|
||||
}
|
||||
}
|
||||
|
||||
console.log(process.env);
|
||||
|
||||
console.log("Adding private keys to agent");
|
||||
var keyNumber = 0;
|
||||
|
||||
|
|
Loading…
Reference in a new issue