Skip to content

Instantly share code, notes, and snippets.

@vnys
Forked from juemura/c9-github-integration.md
Created May 1, 2018 17:54
Show Gist options
  • Select an option

  • Save vnys/6c69eb4866d46bf2929954d778b9d60f to your computer and use it in GitHub Desktop.

Select an option

Save vnys/6c69eb4866d46bf2929954d778b9d60f to your computer and use it in GitHub Desktop.
Tutorial: How to connect your Cloud9 and GitHub accounts via ssh

#Tutorial: How to connect your Cloud9 and GitHub accounts via ssh

To avoid having to enter your username and password EVERY-SINGLE-TIME you push, follow these step-by-step instructions.


#####1. Copy your C9 ssh key. Go to https://c9.io/account/ssh and copy the key below *"Connect to your private git repository"*. It's a very long string that starts with ssh-rsa and ends with your email.

#####2. Paste your C9 ssh key into your GitHub account Go to https://github.com/settings/keys and click New SSH key. Enter a title (a name like Cloud9 is fine), paste the ssh key that you copied in the previous step, and click Add SSH key

#####3. When creating a remote, make sure you "clone with SSH" instead of "clone with HTTPS" This means that, when you type in git remote add origin, you should use a link that looks like this: *git@github.com:*YOUR_USER_NAME/YOUR_REPO_NAME.git. Pay attention to how that differs from *https://github.com/*YOUR_USER_NAME/YOUR_REPO_NAME.git While the first creates a remote that uses ssh authentication, the latter uses https, so it'll always prompt you to enter your username and password to authenticate the connection.


That's it! Next time you push anything, it should authenticate automatically, and you'll never again have to enter your credentials on C9.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment