1.发单个patch
git status 检查状态
git commit 提交修改,提交了之后才能format-patch
git format-patch -1 -s
vim 0001-A-test-patch.patch add some comment
git send-email 0001-A-test-patch.patch --to abc@126.com --cc 123@126.com
2.发patch set
1043 git format-patch -2 -s --cover
1044 vim 0000-cover-letter.patch
1046 vim 0001-Move-the-definition-of-struct-mapped_device-and-stru.patch
1052 vim 0002-Add-the-new-interface-for-multipath-to-limit-the-tim.patch
1054 mkdir send-patch
1055 mv 000* send-patch/
1056 git send-email send-patch/ --to abc@126.com
1062 git send-email send-patch/ --to abc@126.com --cc def@126.com
方法一:
[root@yuxh linux-2.6]# cat .git/config
[core]