From 71155bedbe68a1b45faad7d6a3b890a789338f44 Mon Sep 17 00:00:00 2001 From: Matthias Pigulla Date: Tue, 2 Mar 2021 18:27:44 +0000 Subject: [PATCH] Poke at things with a stick --- .github/workflows/demo.yml | 40 -------------------------------------- dist/index.js | 6 +++--- index.js | 6 +++--- 3 files changed, 6 insertions(+), 46 deletions(-) diff --git a/.github/workflows/demo.yml b/.github/workflows/demo.yml index ca01bf9..18d5522 100644 --- a/.github/workflows/demo.yml +++ b/.github/workflows/demo.yml @@ -1,46 +1,6 @@ on: [push, pull_request] jobs: - single_key_demo: - strategy: - matrix: - os: [ubuntu-latest, macOS-latest, windows-latest] - runs-on: ${{ matrix.os }} - steps: - - uses: actions/checkout@v2 - - name: Setup key - uses: ./ - with: - ssh-private-key: | - ${{ secrets.DEMO_KEY }} - ${{ secrets.DEMO_KEY_2 }} - - multiple_keys_demo: - strategy: - matrix: - os: [ubuntu-latest, macOS-latest] - runs-on: ${{ matrix.os }} - steps: - - uses: actions/checkout@v2 - - name: Setup key - uses: ./ - with: - ssh-private-key: ${{ secrets.DEMO_KEY }} - - docker_demo: - runs-on: ubuntu-latest - container: - image: ubuntu:latest - steps: - - uses: actions/checkout@v2 - - run: apt update && apt install -y openssh-client - - name: Setup key - uses: ./ - with: - ssh-private-key: | - ${{ secrets.DEMO_KEY }} - ${{ secrets.DEMO_KEY_2 }} - deployment_keys_demo: env: GIT_SSH_COMMAND: ssh -v diff --git a/dist/index.js b/dist/index.js index 45cc293..0b4fae7 100644 --- a/dist/index.js +++ b/dist/index.js @@ -138,10 +138,10 @@ try { child_process.execSync('sc config ssh-agent start=demand', { stdio: 'inherit' }); // Work around https://github.com/PowerShell/openssh-portable/pull/447 by creating a \dev\tty file - fs.mkdirSync('c:\\dev'); + /*fs.mkdirSync('c:\\dev'); fs.closeSync(fs.openSync('c:\\dev\\tty', 'a')); fs.mkdirSync('d:\\dev'); - fs.closeSync(fs.openSync('d:\\dev\\tty', 'a')); + fs.closeSync(fs.openSync('d:\\dev\\tty', 'a'));*/ home = os.homedir(); } else { @@ -219,7 +219,7 @@ try { // On Linux and OS X, IdentitiesOnly=no will send all keys from agent before the explicit key, so use "yes". // On Windows, IdentitiesOnly=yes will ignore keys from the agent, but send explicit keys first; so use "no" (https://github.com/PowerShell/Win32-OpenSSH/issues/1550) - let identitiesOnly = 'yes'; // isWindows ? 'no' : 'yes'; + let identitiesOnly = isWindows ? 'no' : 'yes'; let sshConfig = `\nHost key-${keyNumber}\n` + ` HostName github.com\n` diff --git a/index.js b/index.js index 58eaa20..1e881ea 100644 --- a/index.js +++ b/index.js @@ -21,10 +21,10 @@ try { child_process.execSync('sc config ssh-agent start=demand', { stdio: 'inherit' }); // Work around https://github.com/PowerShell/openssh-portable/pull/447 by creating a \dev\tty file - fs.mkdirSync('c:\\dev'); + /*fs.mkdirSync('c:\\dev'); fs.closeSync(fs.openSync('c:\\dev\\tty', 'a')); fs.mkdirSync('d:\\dev'); - fs.closeSync(fs.openSync('d:\\dev\\tty', 'a')); + fs.closeSync(fs.openSync('d:\\dev\\tty', 'a'));*/ home = os.homedir(); } else { @@ -102,7 +102,7 @@ try { // On Linux and OS X, IdentitiesOnly=no will send all keys from agent before the explicit key, so use "yes". // On Windows, IdentitiesOnly=yes will ignore keys from the agent, but send explicit keys first; so use "no" (https://github.com/PowerShell/Win32-OpenSSH/issues/1550) - let identitiesOnly = 'yes'; // isWindows ? 'no' : 'yes'; + let identitiesOnly = isWindows ? 'no' : 'yes'; let sshConfig = `\nHost key-${keyNumber}\n` + ` HostName github.com\n`