Skip to content

Instantly share code, notes, and snippets.

@andrey-zakharov
Created September 29, 2021 18:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save andrey-zakharov/d3f38e24618b7e65c5e7027db7af9fdb to your computer and use it in GitHub Desktop.
Save andrey-zakharov/d3f38e24618b7e65c5e7027db7af9fdb to your computer and use it in GitHub Desktop.
export your patches to plain patch files
git log --diff-merges=none --author="$(git config user.name)" --format="format:%h#%aD#%f"| \
while IFS=# read c d m; do \
r=~/Documents/my-commits/$m.patch; \
git diff $c --output $r; touch -d "$d" $r; \
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment