Step 1: set up secure shell
- The following secure shell (SSH) setup tutorial is based on this video.
- Skip this step if you can already clone our repositories.
generate a key-pair
- Go to the
.ssh folder in your home directory (create one if it does not exist):
- Type the following in your terminal:
ssh-keygen -t ed25519 -f id_github -C your-email@example.com
- Press Enter twice if you want to skip making a passphrase.
- The
-t ed25519 option indicates that we will use this particular type of encryption for the key-pair.
- The command creates two files: a private key
id_github and a public key id_github.pub
edit the configuration file
- Edit/create the ssh configuration file using any text editor. For instance,
- Put the following in the configuration file:
Host GitHub_or_whatever_alias_you_want
HostName github.com
User git
IdentityFile ~/.ssh/id_github
AddKeysToAgent yes
(quit vim by pressing Esc, then : (colon), then type wq to write and quit, hit Enter).
give GitHub the PUBLIC key
- Go to the GitHub SSH and GPG keys setting page
- Click on the green "New SSH key" button on the top right corner.
- Enter whatever you want as the Title, for example
OSC Cardinal.
- Leave the Key type as "Authentication Key".
- Go back to the terminal and type to print out the public key.
- Copy whatever
cat returns on your terminal to the field Key on GitHub - Attention
- It is important that you are copying the public key!
- click the green "Add SSH key" button.
confirmation
- start the ssh agent with You should see something like
Agent pid 6563.
- Check that the key works through
ssh -T GitHub_or_whatever_alias_you_want
(and enter yes if the computer asks you whether or not to continue connecting to github.com.) - Note
- Additionally, you might want to put these two commands in your
.bashrc or equivalent.
This way, they are executed automatically next time you log in/start a new session.
- If you see the following greeting message, it means you have suceeded:
Hi XXX! You've successfully authenticated, but GitHub does not provide shell access.
Step 2: clone the repo
Run the following command to download pueoBuilder to, for example, your home directory:
git clone git@github.com:PUEOCollaboration/pueoBuilder.git ${HOME}/pueoBuilder