mirror of
https://github.com/webfactory/ssh-agent.git
synced 2024-12-22 06:53:28 +00:00
Handle missing newline in private key
This commit is contained in:
parent
dc588b651f
commit
fe9075dfa6
5 changed files with 3994 additions and 3998 deletions
3888
dist/cleanup.js
vendored
3888
dist/cleanup.js
vendored
File diff suppressed because it is too large
Load diff
4056
dist/index.js
vendored
4056
dist/index.js
vendored
File diff suppressed because it is too large
Load diff
6
index.js
6
index.js
|
@ -5,7 +5,11 @@ const crypto = require('crypto');
|
|||
const { homePath, sshAgentCmdDefault, sshAddCmdDefault, gitCmdDefault } = require('./paths.js');
|
||||
|
||||
try {
|
||||
const privateKey = core.getInput('ssh-private-key');
|
||||
let privateKey = core.getInput('ssh-private-key');
|
||||
// Add a newline at the end of the private key if it is not already there
|
||||
if (privateKey && privateKey.slice(-1) !== '\n') {
|
||||
privateKey += '\n';
|
||||
}
|
||||
const logPublicKey = core.getBooleanInput('log-public-key', {default: true});
|
||||
|
||||
const sshAgentCmdInput = core.getInput('ssh-agent-cmd');
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
"license": "MIT",
|
||||
"devDependencies": {
|
||||
"@actions/core": "^1.9.1",
|
||||
"@zeit/ncc": "^0.20.5"
|
||||
"@vercel/ncc": "^0.38.1"
|
||||
},
|
||||
"scripts": {
|
||||
"build": "node scripts/build.js"
|
||||
|
|
40
yarn.lock
40
yarn.lock
|
@ -3,31 +3,31 @@
|
|||
|
||||
|
||||
"@actions/core@^1.9.1":
|
||||
"integrity" "sha512-5ad+U2YGrmmiw6du20AQW5XuWo7UKN2052FjSV7MX+Wfjf8sCqcsZe62NfgHys4QI4/Y+vQvLKYL8jWtA1ZBTA=="
|
||||
"resolved" "https://registry.npmjs.org/@actions/core/-/core-1.9.1.tgz"
|
||||
"version" "1.9.1"
|
||||
version "1.9.1"
|
||||
resolved "https://registry.npmjs.org/@actions/core/-/core-1.9.1.tgz"
|
||||
integrity sha512-5ad+U2YGrmmiw6du20AQW5XuWo7UKN2052FjSV7MX+Wfjf8sCqcsZe62NfgHys4QI4/Y+vQvLKYL8jWtA1ZBTA==
|
||||
dependencies:
|
||||
"@actions/http-client" "^2.0.1"
|
||||
"uuid" "^8.3.2"
|
||||
uuid "^8.3.2"
|
||||
|
||||
"@actions/http-client@^2.0.1":
|
||||
"integrity" "sha512-PIXiMVtz6VvyaRsGY268qvj57hXQEpsYogYOu2nrQhlf+XCGmZstmuZBbAybUl1nQGnvS1k1eEsQ69ZoD7xlSw=="
|
||||
"resolved" "https://registry.npmjs.org/@actions/http-client/-/http-client-2.0.1.tgz"
|
||||
"version" "2.0.1"
|
||||
version "2.0.1"
|
||||
resolved "https://registry.npmjs.org/@actions/http-client/-/http-client-2.0.1.tgz"
|
||||
integrity sha512-PIXiMVtz6VvyaRsGY268qvj57hXQEpsYogYOu2nrQhlf+XCGmZstmuZBbAybUl1nQGnvS1k1eEsQ69ZoD7xlSw==
|
||||
dependencies:
|
||||
"tunnel" "^0.0.6"
|
||||
tunnel "^0.0.6"
|
||||
|
||||
"@zeit/ncc@^0.20.5":
|
||||
"integrity" "sha512-XU6uzwvv95DqxciQx+aOLhbyBx/13ky+RK1y88Age9Du3BlA4mMPCy13BGjayOrrumOzlq1XV3SD/BWiZENXlw=="
|
||||
"resolved" "https://registry.npmjs.org/@zeit/ncc/-/ncc-0.20.5.tgz"
|
||||
"version" "0.20.5"
|
||||
"@vercel/ncc@^0.38.1":
|
||||
version "0.38.1"
|
||||
resolved "https://registry.yarnpkg.com/@vercel/ncc/-/ncc-0.38.1.tgz#13f08738111e1d9e8a22fd6141f3590e54d9a60e"
|
||||
integrity sha512-IBBb+iI2NLu4VQn3Vwldyi2QwaXt5+hTyh58ggAMoCGE6DJmPvwL3KPBWcJl1m9LYPChBLE980Jw+CS4Wokqxw==
|
||||
|
||||
"tunnel@^0.0.6":
|
||||
"integrity" "sha512-1h/Lnq9yajKY2PEbBadPXj3VxsDDu844OnaAo52UVmIzIvwwtBPIuNvkjuzBlTWpfJyUbG3ez0KSBibQkj4ojg=="
|
||||
"resolved" "https://registry.npmjs.org/tunnel/-/tunnel-0.0.6.tgz"
|
||||
"version" "0.0.6"
|
||||
tunnel@^0.0.6:
|
||||
version "0.0.6"
|
||||
resolved "https://registry.npmjs.org/tunnel/-/tunnel-0.0.6.tgz"
|
||||
integrity sha512-1h/Lnq9yajKY2PEbBadPXj3VxsDDu844OnaAo52UVmIzIvwwtBPIuNvkjuzBlTWpfJyUbG3ez0KSBibQkj4ojg==
|
||||
|
||||
"uuid@^8.3.2":
|
||||
"integrity" "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg=="
|
||||
"resolved" "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz"
|
||||
"version" "8.3.2"
|
||||
uuid@^8.3.2:
|
||||
version "8.3.2"
|
||||
resolved "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz"
|
||||
integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==
|
||||
|
|
Loading…
Reference in a new issue