Quantcast
Channel: First steps - JuliaLang
Viewing all articles
Browse latest Browse all 2795

2-step guide for github repos with Pkg

$
0
0

Sufficient conditions for 1 and 2 to “just work”

  1. you are using some version of linux
  2. you ran ssh-keygen and hit enter until the prompts stopped
    1. ensure that ~/.ssh/id_rsa exists afterward
  3. you have followed these instructions for key exchange with github

1. Single session (interactive, works until you reboot):

run the following two lines (in order):

  1. eval "$(ssh-agent -s)"
  2. ssh-add ~/.ssh/id_rsa

2. Every session (non-interactive, runs at boot):

copy the following into your ~/.bashrc, then restart:

SSH_ENV="$HOME/.ssh/agent-environment"

function start_agent {
    echo "Initialising new SSH agent..."
    /usr/bin/ssh-agent | sed 's/^echo/#echo/' > "${SSH_ENV}"
    echo succeeded
    chmod 600 "${SSH_ENV}"
    . "${SSH_ENV}" > /dev/null
    /usr/bin/ssh-add;
}

# Source SSH settings, if applicable

if [ -f "${SSH_ENV}" ]; then
    . "${SSH_ENV}" > /dev/null
    #ps ${SSH_AGENT_PID} doesn't work under cywgin
    ps -ef | grep ${SSH_AGENT_PID} | grep ssh-agent$ > /dev/null || {
        start_agent;
    }
else
    start_agent;
fi

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 2795

Latest Images

Trending Articles



Latest Images