Skip to content

GitHub

If you don’t yet have a GitHub account, you can create one at GitHub.

Create a Repository

Click the New button to create a new repository.

Clone the Repository

Setting up SSH

First check if you already have a SSH key:

Terminal window
ls -al ~/.ssh

If you see a file named id_rsa.pub, or similar, you already have a SSH key. If not, you can generate one:

Terminal window
ssh-keygen -t ed25519

Copy the SSH key to your clipboard:

Terminal window
cat ~/.ssh/id_*.pub

Add the SSH key to your GitHub account:

  • Go to your GitHub SSH settings.
  • Add a title, e.g. “My laptop”.
  • Paste the key into the “Key” field.

Cloning the Repository

  • Get the repository URL by clicking the green “Code” button.
  • Select the “SSH” tab and copy the URL.
  • Clone the repository to your local machine:
Terminal window
# git clone ...
# Replace <username> with your GitHub username, and the repo name if you changed it
git clone git@github.com:<username>/python-gh-actions.git
cd python-gh-actions

Validate that you have successfully cloned the repository:

Terminal window
cat README.md