• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
Effective Git
 

Effective Git

on

  • 1,311 views

 

Statistics

Views

Total Views
1,311
Views on SlideShare
1,308
Embed Views
3

Actions

Likes
1
Downloads
10
Comments
0

1 Embed 3

http://coderwall.com 3

Accessibility

Categories

Upload Details

Uploaded via as Adobe PDF

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

    Effective Git Effective Git Presentation Transcript

    • Andrzej GrzesikKonrad MalawskiLunarLogicPolska
    • Ask them right away!
    • a distributed open source version control system
    • is also fast reliable powerful popular
    • •  it is too new•  not tested•  does not provide backups (sic!)•  does not like windows•  does not support ...•  its not subversion
    • Git is "simple" but hard.Subversion is "easy", but eventually complex. Thomas Nicolaisen (http://blog.tfnico.com/2011/11/some-thoughts-on-git-vs-complexity.html)
    • git config --global user.name Sheldon Coopergit config --global user.email bazinga@bigbang.comgit config --global color.ui true
    • •  cherry-pick•  rebase (interactive)•  interactive add•  submodules•  git svn•  git sh
    • # initialize a submodulegit submodule add git://llp.pl/common.git common# initial pull of its contentsgit submodule init# pull pointed to commit (and overwrite your changes)git submodule update
    • cd commongit pullcd ..# Warning! Add the dir without trailing "/”git add commongit commit -m "Latest common submodule commit"
    • ... or "Why merge isnt enough?"
    • https://github.com/ktoso/maven-git-commit-id-plugin
    • Keeping commit info in UI of the running app,results in better (or less!) bug reports :-)
    • Or expose full details, for developers only@InjectGitRepositoryState repoState;@GET@Path("/git")public GitRepositoryState getRepoState(){ return repoState;} { "branch" : "testing-maven-git-plugin", "commitTime" : "06.01.1970 @ 16:16:26 CET", "commitId" : "787e39f61f99110e74deed68ab9093088d64b969", "commitIdAbbrev" : "787e39f", "commitUserName" : "Konrad Malawski", "commitUserEmail" : "konrad.malawski@java.pl", "commitMessageFull" : "releasing my fun plugin :-) + fixed some typos + cleaned up directory structure + added license etc", "commitMessageShort" : "releasing my fun plugin :-)", "buildTime" : "06.01.1970 @ 16:17:53 CET", "buildUserName" : "Konrad Malawski", "buildUserEmail" : "konrad.malawski@java.pl" }
    • De facto standard of viewing git-based repositoriesJust point it to the repoWorks through Apache and CGI
    • simple, read/write permissionsper-repositoryssh-key based authenticationbut its trivial to expose config file via f.ex. Grails frontend
    • online code review(like ReviewBoard, but better ;-))also hosts git repositories review commits before they enter a branch
    •     with some help        by the power of Jenkins,             allows to have pre-tested commits
    • Git immersion:http://library.edgecase.com/git_immersion/index.htmlOn branching with Githttp://nvie.com/posts/a-successful-git-branching-model/Pro Git book (creative commons)www.progit.orgGit-scm.comGit.wiki.kernel.org