Setting Up Git For Your Project Part 3

Generating SSH Key

SSH Key is use for authentication.

Step 1: Check if you already have SSH key

  1. Open Git Bash.
  2. Enter ls -al ~/.ssh to see the existing SSH Keys

git10.png

Step 2:  Generating a New SSH Key

  1. Open Git Bash
  2. Past the below command and use your mail id .
    1. ssh-keygen -t rsa -C “yourusername@example.com”
  3. It is asking for file name , do not enter any thing just hit Enter key it will create file with default name.
  4. Enter Password
  5. Enter same Password again and hit Enter
  6. Key Generated.

git11.png

git12

Step 3 : Get the generated SSH Key

  1. Run the below command to get key
    1. notepad .ssh/id_rsa.pub [it will open the file in notepad from where you can copy your key for next step.]

git13.png

 

Step 4: Add SSH key into Git hub

  1. login into git hub
  2. go to settings  [setting can be found under the menu at top right corner your image drop-down menu ]
  3. go to SSH and GPG Keys
  4. Click Add New SSH Key
  5. Enter title and paste the key which we have copied from last step.
  6. click Add SSH Key

git14

git15

git16

 

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s