Create patch from commit Create patch from commit Back Create the last 5 commits as a patch git format-patch -5 HEAD