{"thread":{"id":"19878","subject":"Confusion using git on svn server","startedAt":"2009-06-20T20:28:21Z","lastAt":"2009-06-22T06:16:14Z","messageCount":5,"participants":["Matthieu Stigler","Florian Weimer"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"116682","messageId":"4A3D4665.9040003@gmail.com","threadId":"19878","inReplyTo":null,"subject":"Confusion using git on svn server","fromName":"Matthieu Stigler","fromEmail":"matthieu.stigler@gmail.com","sentAt":"2009-06-20T20:28:21Z","receivedAt":"2009-06-20T20:28:21Z","isPatch":false,"sender":{"key":"matthieu.stigler@gmail.com","avatar":null},"body":"Hi\n\nI just began using git on a svn file, which seems really nice. I'm for \nnow confused with a git operation, as maybe my mind is still thinking \nwith svn vision.\n\nAs I understood, unlike svn, you can make many commit without sending \nthem to the server, and then then sending them in one block with git-svn \ndcommit (if I'm right, with push if git server).\n\nSo two questions:\n-Where can I find documentation on that? Didn't find mention on it in \ngit user manual or git-svn crash course.\n\n-say I want to know, before doing git-svn dcommit, which commits will be \nsent, and if this will do a conflict... is there a way to check that \nbefore sending the commits?\n\nMy main concern is that in my git log, I have a commit and its \"revert\", \nwill it be sent as two different commits to svn? I would love they are \nnot sent at all as they represent a \"neutral\" operation.\n\nThanks a lot!\n"},{"id":"116700","messageId":"87zlc258nj.fsf@mid.deneb.enyo.de","threadId":"19878","inReplyTo":"4A3D4665.9040003@gmail.com","subject":"Re: Confusion using git on svn server","fromName":"Florian Weimer","fromEmail":"fw@deneb.enyo.de","sentAt":"2009-06-21T07:49:04Z","receivedAt":"2009-06-21T07:49:04Z","isPatch":false,"sender":{"key":"fw@deneb.enyo.de","avatar":null},"body":"* Matthieu Stigler:\n\n> My main concern is that in my git log, I have a commit and its\n> \"revert\", will it be sent as two different commits to svn? I would\n> love they are not sent at all as they represent a \"neutral\" operation.\n\nThey will be sent as a separate commits by default.\n\nYou can use \"git rebase -i git-svn\" to edit your local history before\nsubmitting it, though.\n"},{"id":"116701","messageId":"4A3DF8BE.2050504@gmail.com","threadId":"19878","inReplyTo":"87zlc258nj.fsf@mid.deneb.enyo.de","subject":"Re: Confusion using git on svn server","fromName":"Matthieu Stigler","fromEmail":"matthieu.stigler@gmail.com","sentAt":"2009-06-21T09:09:18Z","receivedAt":"2009-06-21T09:09:18Z","isPatch":false,"sender":{"key":"matthieu.stigler@gmail.com","avatar":null},"body":"Florian Weimer a écrit :\n> * Matthieu Stigler:\n>\n>   \n>> My main concern is that in my git log, I have a commit and its\n>> \"revert\", will it be sent as two different commits to svn? I would\n>> love they are not sent at all as they represent a \"neutral\" operation.\n>>     \n>\n> They will be sent as a separate commits by default.\n>\n> You can use \"git rebase -i git-svn\" to edit your local history before\n> submitting it, though.\n> --\n> To unsubscribe from this list: send the line \"unsubscribe git\" in\n> the body of a message to majordomo@vger.kernel.org\n> More majordomo info at  http://vger.kernel.org/majordomo-info.html\n>   \nExcellent! This is exactly what I was looking for, thanks!\n\nI had a minor issue as the commits I wanted to remove (a modif and its \nrevert) were the last one, so I could not remove both in the same time, \nas said:\n\nHowever, if you remove everything, the rebase will be aborted.\n\n\nSo I just added a minor third commit in order to remove the two first. \nIs there a better way to do than this workaround? Something with git \nrebase --onto (two last?)\n\nThanks a lot!\n"},{"id":"116705","messageId":"87ws763pa1.fsf@mid.deneb.enyo.de","threadId":"19878","inReplyTo":"4A3DF8BE.2050504@gmail.com","subject":"Re: Confusion using git on svn server","fromName":"Florian Weimer","fromEmail":"fw@deneb.enyo.de","sentAt":"2009-06-21T09:32:54Z","receivedAt":"2009-06-21T09:32:54Z","isPatch":false,"sender":{"key":"fw@deneb.enyo.de","avatar":null},"body":"* Matthieu Stigler:\n\n> So I just added a minor third commit in order to remove the two\n> first. Is there a better way to do than this workaround? Something\n> with git rebase --onto (two last?)\n\nIf you want to remove the last two commits, you can use \"git reset\nHEAD^^\".  This moves your working copy (and the associated master\nbranch) back in time.\n"},{"id":"116738","messageId":"877hz4ssi9.fsf@mid.deneb.enyo.de","threadId":"19878","inReplyTo":"fabb9a1e0906212304o2b61d081i4cf72300be8bd775@mail.gmail.com","subject":"Re: Confusion using git on svn server","fromName":"Florian Weimer","fromEmail":"fw@deneb.enyo.de","sentAt":"2009-06-22T06:16:14Z","receivedAt":"2009-06-22T06:16:14Z","isPatch":false,"sender":{"key":"fw@deneb.enyo.de","avatar":null},"body":"* Sverre Rabbelier:\n\n> It moves your tree only if you add --hard, although in case of a reverted\n> revert it doesn't matter.\n\nWell, this is part of the checkout/reset confusion.  Even without\n--hard, reset changes where the working tree is located in the\nhistory.  But it doesn't perform a checkout.\n\nAs you said, with a rever, this shouldn't matter.\n"}]}