0
EGit 1.0 - Git integration in Eclipse <ul><li>Software Configuration Management
Git
Egit
Take away
Further readings
Q & A </li></ul>Eclipse Democamp 2011 Bucharest, Romania Antonel Ernest Pazargic
EGit 1.0 - Git integration in Eclipse <ul>Software Configuration Management <li>Types: </li><ul><li>Centralized </li><ul><...
server based
bottleneck </li></ul><li>Decentralized </li><ul><li>any participant can act as both server and client.
disconnected operation
complete history
backups are trivial
Speed </li></ul></ul></ul>Eclipse Democamp 2011 Bucharest, Romania
EGit 1.0 - Git integration in Eclipse <ul>Git   History <ul><li>Before April 6, 2005 Linux development have been using Bit...
Linux Git was initially designed and developed by Linus Torvalds.
Since June 16, 2005 the entire Linux kernel is developed using the Git distributed SCM.
February 14, 2007 GIT 1.5.0 was released </li></ul></ul>Eclipse Democamp 2011 Bucharest, Romania
EGit 1.0 - Git integration in Eclipse <ul>Git   Installation <ul><li>Linux </li><ul><ul><li>$ yum install git-core
$ apt-get install git-core </li></ul></ul><li>Mac 10.4 </li><ul><ul><li>In both Mac 10.4 and 10.5, you can install Git via...
$ sudo port install git-core </li></ul></ul><li>Windows </li><ul><ul><li>On Windows, installing Git is pretty easy. Simply...
EGit 1.0 - Git integration in Eclipse <ul>Git   Components <ul><li>Working tree: directories, files
Repository contents: files, commits, ancestry
DAG Directed Acyclic Graph
References: Tags, Branches
Upcoming SlideShare
Loading in...5
×

Egit 1.0

1,179

Published on

EGit - Git integration in Eclipse Indigo

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
1,179
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
15
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Transcript of "Egit 1.0"

  1. 1. EGit 1.0 - Git integration in Eclipse <ul><li>Software Configuration Management
  2. 2. Git
  3. 3. Egit
  4. 4. Take away
  5. 5. Further readings
  6. 6. Q & A </li></ul>Eclipse Democamp 2011 Bucharest, Romania Antonel Ernest Pazargic
  7. 7. EGit 1.0 - Git integration in Eclipse <ul>Software Configuration Management <li>Types: </li><ul><li>Centralized </li><ul><li>single point of failure
  8. 8. server based
  9. 9. bottleneck </li></ul><li>Decentralized </li><ul><li>any participant can act as both server and client.
  10. 10. disconnected operation
  11. 11. complete history
  12. 12. backups are trivial
  13. 13. Speed </li></ul></ul></ul>Eclipse Democamp 2011 Bucharest, Romania
  14. 14. EGit 1.0 - Git integration in Eclipse <ul>Git History <ul><li>Before April 6, 2005 Linux development have been using BitKeeper (BitMover drops free license).
  15. 15. Linux Git was initially designed and developed by Linus Torvalds.
  16. 16. Since June 16, 2005 the entire Linux kernel is developed using the Git distributed SCM.
  17. 17. February 14, 2007 GIT 1.5.0 was released </li></ul></ul>Eclipse Democamp 2011 Bucharest, Romania
  18. 18. EGit 1.0 - Git integration in Eclipse <ul>Git Installation <ul><li>Linux </li><ul><ul><li>$ yum install git-core
  19. 19. $ apt-get install git-core </li></ul></ul><li>Mac 10.4 </li><ul><ul><li>In both Mac 10.4 and 10.5, you can install Git via MacPorts.
  20. 20. $ sudo port install git-core </li></ul></ul><li>Windows </li><ul><ul><li>On Windows, installing Git is pretty easy. Simply download and install the msysGit package. </li></ul></ul></ul></ul>Eclipse Democamp 2011 Bucharest, Romania
  21. 21. EGit 1.0 - Git integration in Eclipse <ul>Git Components <ul><li>Working tree: directories, files
  22. 22. Repository contents: files, commits, ancestry
  23. 23. DAG Directed Acyclic Graph
  24. 24. References: Tags, Branches
  25. 25. HEAD: current checkout, points to branch, detached
  26. 26. Index (Staging area): what is to be committed </li></ul></ul>Eclipse Democamp 2011 Bucharest, Romania
  27. 27. EGit 1.0 - Git integration in Eclipse <ul>Git Basic operations: <ul><li>Bootstrap: init
  28. 28. Modify: add, delete(rm), rename(mv), commit
  29. 29. Information: status, log, diff
  30. 30. Reference: tag, branch
  31. 31. Remote: clone, pull/fetch, push </li></ul></ul>Eclipse Democamp 2011 Bucharest, Romania
  32. 32. EGit 1.0 - Git integration in Eclipse <ul>Git Structure <ul><li>.git/config private configuration
  33. 33. .git/description describe the repository
  34. 34. .git/info/exclude ignore based on patterns
  35. 35. .git/objects </li><ul><li>Immutable
  36. 36. Loose objects based on SHA1.
  37. 37. Pack files
  38. 38. Object: type, size & containt. Types: tree, blob, commit, tag. </li></ul></ul></ul>Eclipse Democamp 2011 Bucharest, Romania
  39. 39. EGit 1.0 - Git integration in Eclipse <ul>Git Getting help <ul><li>git help #print the list of common commands
  40. 40. man git-<command> # man page of the command (or git command --help)
  41. 41. git command -h #brief help </li></ul></ul>Eclipse Democamp 2011 Bucharest, Romania
  42. 42. EGit 1.0 - Git integration in Eclipse <ul>Git Hands-on. Part 1 <ul><li>cd mydir
  43. 43. mkdir project
  44. 44. git config --global user.name &quot;Antonel Pazargic&quot;
  45. 45. git config --global user.email &quot;a.b@xxxxxx.com&quot;
  46. 46. git init # create the .git directory
  47. 47. echo &quot;Hello git&quot; > test.txt # untracked change
  48. 48. git add test.txt # staged (INDEX)
  49. 49. git commit -m&quot;Test&quot; # HEAD (master). 1st commit so this commit has no parent commit. </li></ul></ul>Eclipse Democamp 2011 Bucharest, Romania
  50. 50. EGit 1.0 - Git integration in Eclipse <ul>Git Hands-on. Part 2 <li>git status # shows staged, unstaged and untracked
  51. 51. git diff # diffs between the index and the working files
  52. 52. git diff $commit1 $commit2 # diffs between two commits (commit could be specified by full/short hash, tag, branch, remote branch)
  53. 53. git diff HEAD # diffs between HEAD and the working files
  54. 54. git diff --staged # diffs between HEAD and the index
  55. 55. git show # review last commit
  56. 56. git show HEAD~3 # ~, ^ special characters to identify a certain
  57. 57. git log # see commit history
  58. 58. git log tag..branch # limit by range
  59. 59. git log HEAD~10.. # limit by range </li></ul>Eclipse Democamp 2011 Bucharest, Romania
  60. 60. EGit 1.0 - Git integration in Eclipse <ul>Git Hands-on. Part 3 <li>git branch -l # list branches
  61. 61. git branch -r # list remote branches
  62. 62. git tag -l # list tags
  63. 63. git checkpout -b bugfix # checkout the current branch and create/switch to a new branch named bugfix
  64. 64. git tag -a -m&quot;RC 1&quot; # create a new tag for RC
  65. 65. git checkout master # switch to master branch
  66. 66. git merge bugfix # merge master with bugfix
  67. 67. git merge $One $Two # octopus merging. Merging master with One and Two
  68. 68. Remote
  69. 69. git clone git://jtonic@repo.com/project.git # replicates remote repository (Git URLs: file://, http://, git://, ssh://) </li></ul>Eclipse Democamp 2011 Bucharest, Romania
  70. 70. EGit 1.0 - Git integration in Eclipse <ul>Git gitk </ul>Eclipse Democamp 2011 Bucharest, Romania
  71. 71. EGit 1.0 - Git integration in Eclipse <ul>EGit <li>Overview
  72. 72. EGit is a team provider for the distributed VCS Git. This tool is built on top of JGit (Java implementation of Git) </li></ul>Eclipse Democamp 2011 Bucharest, Romania
  73. 73. EGit 1.0 - Git integration in Eclipse <ul>Egit Installation Prerequisites: Eclipse 3.7.0 Indigo, Java SE 1.4+ <li>Start Eclipse SDK
  74. 74. Install EGit using Eclipse Update Manager Help>Install New Software...>
  75. 75. Work with:
  76. 76. - http://download.eclipse.org/releases/indigo
  77. 77. - http://download.eclipse.org/egit/updates
  78. 78. Use defaults, restart Workbench/Eclipse </li></ul>Eclipse Democamp 2011 Bucharest, Romania
  79. 79. EGit 1.0 - Git integration in Eclipse <ul>EGit Working with EGit </ul>Eclipse Democamp 2011 Bucharest, Romania <ul>Create a repository </ul><ul>Configure the repository </ul><ul>Git repositories explorer </ul>
  80. 80. EGit 1.0 - Git integration in Eclipse <ul>EGit <li>Working with EGit </li></ul>Eclipse Democamp 2011 Bucharest, Romania <ul>Share a project </ul>
  81. 81. EGit 1.0 - Git integration in Eclipse <ul>EGit <li>Working with EGit </li></ul>Eclipse Democamp 2011 Bucharest, Romania <ul>Git Staging before Add operation </ul><ul>Package explorer NO-HEAD </ul>
  82. 82. EGit 1.0 - Git integration in Eclipse <ul>EGit <li>Working with EGit </li></ul>Eclipse Democamp 2011 Bucharest, Romania <ul>Add to index </ul><ul>Staged changes </ul>
  83. 83. EGit 1.0 - Git integration in Eclipse <ul>Egit <li>Working with EGit </li></ul>Eclipse Democamp 2011 Bucharest, Romania <ul>Commit changes </ul><ul>Git commands </ul>
  84. 84. EGit 1.0 - Git integration in Eclipse <ul>EGit <li>History </li></ul>Eclipse Democamp 2011 Bucharest, Romania
  85. 85. EGit 1.0 - Git integration in Eclipse <ul>EGit <li>Compare with version in ancestor </li></ul>Eclipse Democamp 2011 Bucharest, Romania
  86. 86. EGit 1.0 - Git integration in Eclipse <ul>EGit <li>Git Preferences/Properties </li></ul>Eclipse Democamp 2011 Bucharest, Romania Project Git Properties Project Git Properties Workbench Git Preferences
  87. 87. EGit 1.0 - Git integration in Eclipse <ul>EGit New and noteworthy: Synchronize View Merge Create a Git repository for multiple projects Remote operations: push, pull, clone existing project Clone repository Working with Github (GitHub Connector) Mylyn integration Git Commit Search and Commit Viewer Double clicking a commit in the search result opens the new Commit Viewer </ul>Eclipse Democamp 2011 Bucharest, Romania
  88. 88. EGit 1.0 - Git integration in Eclipse <ul><li>Further reading
  89. 89. http://www.vogella.de/articles/Git/article.html
  90. 90. http://www.vogella.de/articles/EGit/article.html
  91. 91. http://progit.org/book/
  92. 92. http://www.kernel.org/pub/software/scm/git/docs/gittutorial.html
  93. 93. http://www.kernel.org/pub/software/scm/git/docs/user-manual.html
  94. 94. Thank you
  95. 95. Q & A </li></ul>Eclipse Democamp 2011 Bucharest, Romania
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×