Your SlideShare is downloading. ×
  • Like
Introduction To Git
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×

Now you can save presentations on your phone or tablet

Available for both IPhone and Android

Text the download link to your phone

Standard text messaging rates apply

Introduction To Git

  • 378 views
Published

 

  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
No Downloads

Views

Total Views
378
On SlideShare
0
From Embeds
0
Number of Embeds
1

Actions

Shares
Downloads
24
Comments
3
Likes
3

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1. Introduction to Git
  • 2. What is Git and Github?Git is an extremely fast, efficient, distributedversion control system used for collaborativedevelopment of software. Git was designed anddeveloped by Linus Torvalds.Github is a web based hosting service forsoftware development projects that use the Gitrevision control system.
  • 3. Working with Git locally● Creating Projects $ git init● Adding Files to Staging Area $ git add . (add all files recursively) $ git add * (add all files)
  • 4. Working with Git locally● Checking the status of the project $ git status
  • 5. Working with Git locally● Committing changes $ git commit -m first commit
  • 6. Git Branching
  • 7. Git Branching● Branch Command $ git branch [branchname] (creates a branch) $git checkout [branchname] (switch to another branch)
  • 8. Git Branching $git branch (lists existing branch)● Merge branch $git merge [branchname]● Read the commit history $git log
  • 9. Working remotely with git
  • 10. Working remotely with Git
  • 11. Working remotely with Git● Getting the copy of repository $git clone [url]● Adding a remote repository $ git remote add [alias] [url]
  • 12. Working remotely with Git● Updating from a remote repository $ git pull● Updating a remote repository $git push [alias] [branch]
  • 13. Best practices● Always do small, logical commits● Do keep up to date● Always review code before committing it● Do useful tools (eg. sourcetree)