Git create patch series for multipe commits.

Anand Moon moon.linux at yahoo.com
Fri Sep 26 13:35:57 EDT 2014


Hi Shawn,

Thanks I will give it a try.

One more question, if the change belong to single file
and we are fixing multiple issue we need to different commit
for each changes. And then club them into patch series.
Am I right.


-Anand Moon

On Friday, September 26, 2014 7:49 PM, Shawn Bohrer <shawn.bohrer at gmail.com> wrote:



On Thu, Sep 25, 2014 at 09:54:25PM -0700, Anand Moon wrote:
> Hi All,
> 
> Could somebody provide me steps to create patch series.
First take a look at:

$ git help format-patch
$ git help send-email

Assuming you have basic familarity with git, the typical workflow
would be something like this.

# create a patch series of the commits in the current branch that are
# not in origin/master
$ mkdir patches
$ git format-patch -o patches/ -M --cover-letter origin/master

# Edit the cover letter to describe your patch series
$ edit patches/0000*

# Send the patch series
$ git send-email --to maintainer at domain.org --cc list at mailinglist.com patches/

> How to send version's of these patches.

# Fix up review comments
$ git commit -m "roll back into patch foo"
$ git rebase -i origin/master
# Re-order and squash the fix with patch foo


> How to resend these patches.

# Make v2 patch series
$ git format-patch -o patches/ -M --cover-letter -v 2 origin/master
# Make new cover-letter with description of changes in v2
$ edit patches/0000*
# Good practice to also mention the v2 change in the patches you fixed
$ edit patches/*foo*.patch

Repeat steps above.

--
Shawn

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies at kernelnewbies.org
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies



More information about the Kernelnewbies mailing list