Git format-patch to be svn compatible?

前端 未结 8 2166
逝去的感伤
逝去的感伤 2020-12-07 08:19

Is there any way to get a patch created with git format-patch to be svn compatible so that I can submit it to an svn repo?

I\'m working off an svn repo on github and

8条回答
  •  借酒劲吻你
    2020-12-07 08:41

    I always have to Google this but the way I've found that works perfectly (for me) is:

    • Create the patch with git diff --no-prefix master..branch > somefile.diff, the master and branch part are optional, depends how you want to get your diffs.
    • Send it wherever and apply with patch -p0 < somefile.diff.

    It always seems to work fine for me and seems to be the simplest method that I've come across.

提交回复
热议问题