Wednesday, June 26, 2013

Working with GitHub

How to install and configure  GitHub on Ubuntu

Installing  GitHub in ubuntu is very easy.
open terminal and run the following command.
sudo apt-get install git

How to configure GitHub

The first thing you should do when you install Git is to set your user name and e-mail address.To do that enter the following two lines in the terminal.

git config --global "John Doe" # Sets the default name for git to use when you commit

git config --global
# Sets the default email for git to use when you commit

to check your setting use the following command.
git config --list

Fork and Clone an Existing Repository

When you need work  on a project page that looks interesting  you can click the “fork” button in the project header to have GitHub copy that project to your user so you can push to it.
To fork a project, visit the project page (in this case, and click
the “fork” button in the header. After a few seconds, you’re taken to your new project page, which indicates that this project is a fork of another one.

After you have fork the project,if you want to get a copy of an existing Git repository the command you need is git clone.

git clone
#replace vijayindu with your user name.

this will clone the existing repository to your current working directory of your computer.

No comments:

Post a Comment