Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use ssh key saved in ssh-agent if deploy key env var is not set. Fixes #398 #400

Merged
merged 1 commit into from
Oct 14, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions mdoc-sbt/src/main/scala/mdoc/DocusaurusPlugin.scala
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ object DocusaurusPlugin extends AutoPlugin {
"""|#!/usr/bin/env bash
|
|set -eu
|DEPLOY_KEY=${GIT_DEPLOY_KEY:-$GITHUB_DEPLOY_KEY}
|DEPLOY_KEY=${GIT_DEPLOY_KEY:-${GITHUB_DEPLOY_KEY:-}}
|set-up-ssh() {
| echo "Setting up ssh..."
| mkdir -p $HOME/.ssh
Expand All @@ -75,7 +75,7 @@ object DocusaurusPlugin extends AutoPlugin {
|if [[ -n "${DEPLOY_KEY:-}" ]]; then
| set-up-ssh
|else
| echo "Can't setup SSH. To fix this problem, set the GIT_DEPLOY_KEY environment variable."
| echo "No deploy key found. Attempting to auth with ssh key saved in ssh-agent. To use a deploy key instead, set the GIT_DEPLOY_KEY environment variable."
|fi
|
|yarn install
Expand Down