Step 1 : Go to htdocs in command line. cd htdocs
Step 2 : create a directory in htdocs for your project where you want to clone from git.
mkdir laravel
Step 3 : cd laravel
Step 4 : ssh-keygen -t rsa -C "smita2121314@gmail.com" -b 4096
(smita2121314@gmail.com is github username )
Step 5 : Enter file in which you want to save the key.
Provide the filename as smita-github or you can specify any filename. I provided smita-github
Step 6 : Enter passphrase. your identification has been saved in smita-github. Your public key has been saved in smita-github.pub.
Step 7 : vi smita-github.pub
Step 8 : copy the code from this and go to github and paste in ssh key section.(Go to settings. Then in left menu SSH keys, Click on that.Paste the key & give title.Then Add key)
Step 9 :git clone https://github.com/laravel/laravel.git
Step 10 :give username & password of github account
Step 11 :git fetch
Step 12 :git branch