{"thread":{"id":"17663","subject":"git ready: daily git tips","startedAt":"2009-02-08T22:18:28Z","lastAt":"2009-02-10T10:19:31Z","messageCount":5,"participants":["Nick Quaranto","Steven Noonan","Nicolas Pitre","Sitaram Chamarty","Johannes Schindelin"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"103790","messageId":"1234131508141-2294642.post@n2.nabble.com","threadId":"17663","inReplyTo":null,"subject":"git ready: daily git tips","fromName":"Nick Quaranto","fromEmail":"nick@quaran.to","sentAt":"2009-02-08T22:18:28Z","receivedAt":"2009-02-08T22:18:28Z","isPatch":false,"sender":{"key":"nick@quaran.to","avatar":null},"body":"\nI started this blog just around a month ago on a quest to learn more about\ngit on a daily basis and to show others how awesome it is. If you have any\nsuggestions on what content to cover or how things should be done\ndifferently, I would greatly appreciate it. Thanks!\n\nhttp://gitready.com\n-- \nView this message in context: http://n2.nabble.com/git-ready%3A-daily-git-tips-tp2294642p2294642.html\nSent from the git mailing list archive at Nabble.com.\n"},{"id":"103791","messageId":"f488382f0902081424g47c75e3dr664d9f77b3558ffb@mail.gmail.com","threadId":"17663","inReplyTo":"1234131508141-2294642.post@n2.nabble.com","subject":"Re: git ready: daily git tips","fromName":"Steven Noonan","fromEmail":"steven@uplinklabs.net","sentAt":"2009-02-08T22:24:38Z","receivedAt":"2009-02-08T22:24:38Z","isPatch":false,"sender":{"key":"steven@uplinklabs.net","avatar":"https://gravatar.com/avatar/b0cd397a10638433f76e084531aa0af3bef85f8fdb59b1ebe2ddaf168cd100e9?d=mp&s=160"},"body":"On Sun, Feb 8, 2009 at 2:18 PM, Nick Quaranto <nick@quaran.to> wrote:\n>\n> I started this blog just around a month ago on a quest to learn more about\n> git on a daily basis and to show others how awesome it is. If you have any\n> suggestions on what content to cover or how things should be done\n> differently, I would greatly appreciate it. Thanks!\n>\n> http://gitready.com\n\nHeh, I've already got this in my RSS reader. It's got some pretty\nawesome tips. I've learned more about git on there than pretty much\nany other resource.\n\nKeep up the good work. :)\n\n- Steven\n"},{"id":"103886","messageId":"alpine.LFD.2.00.0902091524520.30940@xanadu.home","threadId":"17663","inReplyTo":"1234131508141-2294642.post@n2.nabble.com","subject":"Re: git ready: daily git tips","fromName":"Nicolas Pitre","fromEmail":"nico@cam.org","sentAt":"2009-02-09T20:42:07Z","receivedAt":"2009-02-09T20:42:07Z","isPatch":false,"sender":{"key":"nico@fluxnic.net","avatar":"https://avatars.githubusercontent.com/u/702790?v=4"},"body":"On Sun, 8 Feb 2009, Nick Quaranto wrote:\n\n> \n> I started this blog just around a month ago on a quest to learn more about\n> git on a daily basis and to show others how awesome it is. If you have any\n> suggestions on what content to cover or how things should be done\n> differently, I would greatly appreciate it. Thanks!\n> \n> http://gitready.com\n\nWell done.\n\nOne topic that IMHO you fail to cover, and which is being neglected \nalmost everywhere else too, is the reflog.\n\nThe reflog is really your safety net when working with git.  It records \neverything you do. So even if you screw up a rebase, perform the wrong \nmerge, or any other kind of undesired operation, then you may always go \nback to a previous state.  Either you use -g with 'git log' to see all \nthose recorded states, or even 'git reflog' without any argument to get \na condensed list for HEAD.\n\nThe <branch>@{<spec>} notation can be used anywhere a ref is normally \nrequired.  The special branch \"HEAD\" shows every state the HEAD pointer \nwent through, including branch switches.  The <branch< part can be left \nout to mean \"currently checked-out branch\".\n\nOne thing that I use all the time after a 'git pull' is 'git log @{1}..' \nwhere \"@{1}\" means the first previous tip of the current branch, so \neffectively showing me the log of what the pull brought in my branch.\n\n\nNicolas\n"},{"id":"103940","messageId":"slrngp1ljg.cnd.sitaramc@sitaramc.homelinux.net","threadId":"17663","inReplyTo":"alpine.LFD.2.00.0902091524520.30940@xanadu.home","subject":"Re: git ready: daily git tips","fromName":"Sitaram Chamarty","fromEmail":"sitaramc@gmail.com","sentAt":"2009-02-10T01:20:48Z","receivedAt":"2009-02-10T01:20:48Z","isPatch":false,"sender":{"key":"sitaramc@gmail.com","avatar":"https://avatars.githubusercontent.com/u/43316?v=4"},"body":"On 2009-02-09, Nicolas Pitre <nico@cam.org> wrote:\n> On Sun, 8 Feb 2009, Nick Quaranto wrote:\n>> http://gitready.com\n>\n> Well done.\n>\n> One topic that IMHO you fail to cover, and which is being neglected \n> almost everywhere else too, is the reflog.\n>\n> The reflog is really your safety net when working with git.  It records \n> everything you do. So even if you screw up a rebase, perform the wrong \n> merge, or any other kind of undesired operation, then you may always go \n> back to a previous state.  Either you use -g with 'git log' to see all \n> those recorded states, or even 'git reflog' without any argument to get \n> a condensed list for HEAD.\n>\n> The <branch>@{<spec>} notation can be used anywhere a ref is normally \n> required.  The special branch \"HEAD\" shows every state the HEAD pointer \n> went through, including branch switches.  The <branch< part can be left \n> out to mean \"currently checked-out branch\".\n>\n> One thing that I use all the time after a 'git pull' is 'git log @{1}..' \n> where \"@{1}\" means the first previous tip of the current branch, so \n> effectively showing me the log of what the pull brought in my branch.\n\nAlso, the @{now} notation to get a relative timestamp of the\nreflog is invaluable.  Seeing reflog lines annotated with\n'14 minutes ago' or '17 hours ago' or perhaps '4 days ago',\nreally helps to focus on the commits you're looking for:\n\n    git reflog show @{now}\n    # (the 'show' is not optional in this syntax)\n"},{"id":"103962","messageId":"alpine.DEB.1.00.0902101117320.10279@pacific.mpi-cbg.de","threadId":"17663","inReplyTo":"slrngp1ljg.cnd.sitaramc@sitaramc.homelinux.net","subject":"Re: git ready: daily git tips","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2009-02-10T10:19:31Z","receivedAt":"2009-02-10T10:19:31Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Tue, 10 Feb 2009, Sitaram Chamarty wrote:\n\n> On 2009-02-09, Nicolas Pitre <nico@cam.org> wrote:\n> > On Sun, 8 Feb 2009, Nick Quaranto wrote:\n> >> http://gitready.com\n> >\n> > Well done.\n> >\n> > One topic that IMHO you fail to cover, and which is being neglected \n> > almost everywhere else too, is the reflog.\n> >\n> > The reflog is really your safety net when working with git.  It records \n> > everything you do. So even if you screw up a rebase, perform the wrong \n> > merge, or any other kind of undesired operation, then you may always go \n> > back to a previous state.  Either you use -g with 'git log' to see all \n> > those recorded states, or even 'git reflog' without any argument to get \n> > a condensed list for HEAD.\n> >\n> > The <branch>@{<spec>} notation can be used anywhere a ref is normally \n> > required.  The special branch \"HEAD\" shows every state the HEAD pointer \n> > went through, including branch switches.  The <branch< part can be left \n> > out to mean \"currently checked-out branch\".\n> >\n> > One thing that I use all the time after a 'git pull' is 'git log @{1}..' \n> > where \"@{1}\" means the first previous tip of the current branch, so \n> > effectively showing me the log of what the pull brought in my branch.\n> \n> Also, the @{now} notation to get a relative timestamp of the\n> reflog is invaluable.  Seeing reflog lines annotated with\n> '14 minutes ago' or '17 hours ago' or perhaps '4 days ago',\n> really helps to focus on the commits you're looking for:\n> \n>     git reflog show @{now}\n>     # (the 'show' is not optional in this syntax)\n\nYes, I often use \"git log -g --date=relative\" to get a better \nunderstanding of my recent actions in that particular repository.\n\nAlso do not forget to advertise the new @{-<n>} notation for the n-th last \nbranch you were on (to be part of 1.6.2 AFAIU).  This comes in really \nhandy when you juggle a dozen branches (and happen to commit to the wrong \nbranch ;-)\n\nCiao,\nDscho\n"}]}