News from Git in Eclipse - EclipseCon 2015 Europe
Transcript of News from Git in Eclipse - EclipseCon 2015 Europe
![Page 1: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/1.jpg)
News from Git in Eclipse
Matthias Sohn (SAP)Max Hohenegger
![Page 2: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/2.jpg)
JGit
new ignore implementation
improved submodule support
aggressive gc
security fixes
3.6 Dec 2014
EGit
symlink support
improved submodule support
checkout ours / theirs
![Page 3: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/3.jpg)
much faster
support ** pattern
**/foo/bar matches foo/bar in any directoryabc/** matches everything (infinite depth) under abca/**/b matches "a/b", "a/x/b", "a/x/y/b“ and so on
support ! to negate rules defined previously
.a ignore .a files! lib.a but do track lib.a
New ignore implementation
![Page 4: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/4.jpg)
submodules nested under .git
Improved submodule support
use staging view for submodules(in separate projects)
![Page 5: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/5.jpg)
available on files with conflictsCheckout ours / theirs
![Page 6: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/6.jpg)
Fix Git vulnerability
.GiT
case-insensitive FS
matches .git
GIT~1
Windows short-names
matches .git
.g\u200cit
HFS+ (Mac)
matches .git since \u200c is ignored invisible unicode characterprepare malicious commit
on case-sensitive FS
.GiT/config
GIT~1/refs/heads/master
.g\u200cit/config
checkout on affected platform can manipulate content of .git
➔ fixed in 3.4.2, 3.5.3, 3.6+
![Page 7: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/7.jpg)
JGit
basics for gitattributes
basics for hook support
logging
3.7 Feb 2015
EGit
auto-configure Gerrit
performance improvements
![Page 8: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/8.jpg)
Auto-configure review when cloning from Gerrit
![Page 9: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/9.jpg)
JGit
hooks
move to Java 7
API cleanup
4.0 Jun 2015
EGit
basic git-flow support
e4 smart project import
API to prepare model merge
allow to symlink .git
![Page 10: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/10.jpg)
pre-commitcommit-msg
Hooks
![Page 11: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/11.jpg)
e4 smart project import
![Page 12: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/12.jpg)
JGit
basics for push certificates
improve ignore rules
pack expiration during gc
4.1 Sept 2015
EGit
merge strategy extension point
warn or block commit on errors
compare mode in staging view
![Page 13: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/13.jpg)
plugin externalmerge strategyimplementations
used by EMF to providemodel merge strategy
➔ "EMF Compare and EGit" session by Laurent Delaigue at 16:15 in Theater
Merge strategy extension point
![Page 14: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/14.jpg)
Warn/block commit on errors
![Page 15: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/15.jpg)
Compare Mode in Staging View
![Page 16: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/16.jpg)
JGit
improved s3 support
.gitattributes
clean/smudge filters
basic LFS support
LFS server
cooking for 4.2 Dec 2015
EGit
configure date format
multi-push
external diff/merge tools
configure merge strategy
![Page 17: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/17.jpg)
Custom diff/merge tools (e.g. p4merge)
![Page 18: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/18.jpg)
Versioning large binaries in Git
large binary files can't be packed by Git efficiently
➔ slows down transport➔ gc more expensive and less efficient➔ Git repository quickly becomes bulky➔ Git server load grows
![Page 19: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/19.jpg)
.gitattributesvideo.mp4X.java
Large File Storage (LFS) extension
.git-- objects -- sha1
-- lfs -- objects -- sha256
git server
lfs server
git
lfs
![Page 20: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/20.jpg)
.gitattributesvideo.mp4X.java
LFS configuration
.git-- config objects -- sha1
-- lfs -- objects -- sha256
*.mp4 filter=lfs diff=lfs merge=lfs -text[filter "lfs"]smudge = git-lfs smudge %fclean = git-lfs clean %f
[lfs "http://lfs-server/]access = basic
which files to be handled by LFS ?
lfs clean filter intercepts add
lfs smudge filter intercepts checkout
pre-push hook sends LFS objects to LFS server
![Page 21: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/21.jpg)
.gitattributesvideo.mp4X.java
git add video.mp4
.git-- objects -- sha1
-- lfs -- objects -- sha256
version git-lfs/spec/v1id sha256:5891b5b522...size 6
store meta data in objectsstore big file in lfs objects
lfs clean filter
video.mp4
![Page 22: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/22.jpg)
.gitattributesvideo.mp4X.java
git push origin
.git-- objects -- sha1
-- lfs -- objects -- sha256
git server
lfs server
pre-push hook
version git-lfs/spec/v1id sha256:5891b5b522...size 6
push
video.mp4
![Page 23: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/23.jpg)
.gitattributesvideo.mp4X.java
git fetch/clone, git checkout
.git-- objects -- sha1
-- lfs -- objects -- sha256
git server
lfs server
version git-lfs/spec/v1id sha256:5891b5b522...size 6
fetch all meta-data
checkout loads lazily
video.mp4
![Page 24: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/24.jpg)
+ .gitattributes+ run clean filter on add+ run smudge filter on checkout+ run pre-push hook on push- run filters during diff, merge, handle clone ➔ use external lfs in JGit/EGit with existing LFS server (e.g. GitHub)
- LFS extension implemented in JGit- JGit LFS server- LFS server Gerrit plugin➔ builtin lfs in JGit/EGit with Gerrit / LFS server plugin
LFS support in JGit / Gerrit
![Page 25: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/25.jpg)
Gitflow?workflow & branching strategy
“It forms an elegant mental model that is easy to comprehend and allows team members to develop a shared understanding of the branching and releasing processes.”
- Vincent Driessen
(creator of Gitflow)
![Page 26: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/26.jpg)
Gitflow in a Nutshell
Author: Vincent DriessenOriginal blog post: http://nvie.com/posts/a-succesful-git-branching-modelLicense: Creative Commons BY-SA
![Page 27: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/27.jpg)
Gitflow in Eclipse
functional but not finished
+ feature start, finish, checkout, rebase
+ release start, start from commit, finish
+ hotfix start, finish
- several optional parameters
- support branches
![Page 28: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/28.jpg)
Gitflow integration - Demo
![Page 29: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/29.jpg)
GitflowWhat’s next?
it depends on you
- Gerrit integration
- Mylyn integration
- Maintaining features and releases
- ...
![Page 30: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/30.jpg)
Questions & Answers
![Page 31: News from Git in Eclipse - EclipseCon 2015 Europe](https://reader031.fdocuments.in/reader031/viewer/2022022201/589fd61e1a28abf06d8b5e21/html5/thumbnails/31.jpg)