From mboxrd@z Thu Jan 1 00:00:00 1970 From: bjorn@mork.no (=?utf-8?Q?Bj=C3=B8rn_Mork?=) Date: Fri, 12 Dec 2014 16:43:58 +0100 Subject: Query on git usage for creating patch with incremental commits In-Reply-To: <20141212145825.GA5120@gmail.com> (Kumar Amit Mehta's message of "Fri, 12 Dec 2014 15:58:25 +0100") References: <20141212145825.GA5120@gmail.com> Message-ID: <87oar87u0x.fsf@nemi.mork.no> To: kernelnewbies@lists.kernelnewbies.org List-Id: kernelnewbies.lists.kernelnewbies.org Kumar Amit Mehta writes: > So far so good, but what If, I am not particularly proud of the first > patch, but have to send that anyway, If my patches are to be applied. > Another approach would be to create another branch, say development-again, > based of origin/master and make the necessary changes and then just > create one patch file. But I was wondering that while doing development, > don't we make commits in our working branches, which we think is > correct, only to find it ridiculous later (say after few more commits > in future) ? And what to do in such scenario ? Or how to use git to > solve such scenario. git rebase is made for things like this. See http://git-scm.com/book/en/v2/Git-Tools-Rewriting-History Bj?rn