Friday, December 7, 2012

Installing Git

View Sagar Gugwad's profile on LinkedIn
This blog provides guidance to install git on  the Ubuntu. After that we will follow the instructions to setup the project on the local machine.

  1.  Press Ctrl + Alt + T on your Ubuntu machine. This will pops up the terminal in your machines. There are multiple ways to open a terminal. Please note that using commands is powerful and a good practice, therefore we will stick to commands rather than GUI.                                                           
  2. Type in the following command
    • sudo apt-get install git-core
  3. Verify the successful installation by command, which should fetch you installation path
    • which git
  4. Configure your username using following command
    • git config --global user.name  "yourname"
  5. Configure your email using following command
    • git config --global user.email "your@email.address"
  6. Configure your diff tool by setting it upto meld (you can also use other editors, I prefer meld)
    • git config --global merge.tool meld
  7. Cloning the project in your preferred directory 
    • git clone git@github.com:geekgugi/mSIS.git
  8. Change your branch (by default it will be pointing master branch)  to dev branch by following command
    • git checkout -b dev -t origin/dev
  9. We are ready to launch for few git commands
    • git branch -a shows the branch you are in
    • git status shows changes you have made
    • git commit used to commit your changes to local 
    • git log shows commit done by other developers
For more details,  you can go through http://git-scm.com/book/en/Getting-Started which will give you clear idea to work with git.








      No comments:

      Post a Comment