Changed attached diff Content-Type to text/x-diff #5

merged 3 commits into from Aug 9, 2012


None yet

2 participants


Some mail readers (such as mutt) rely on the Content-Type rather than
the file extension in order to determine the type of an attachment.
This commit sets attached diffs to use the far more descriptive
text/x-diff content-type, rather than text/plain.


I suspect that a lot of mail readers will not know what to do with that content-type. I think better would be to add an option to set the content type. Perhaps a --diff-content-type option?


Which do you consider to be the better default -- the existing text/plain or text/x-diff as above?

dpwright added some commits Jul 23, 2012
@dpwright dpwright Add --diff-content-type parameter
This parameter sets the Content-Type header for attached diffs, which is
useful for some mailers.  It defaults to 'text/plain'.
@dpwright dpwright Add documentation for --diff-content-type f353c8f
@dpwright dpwright Realigned parameters
The '--diff-content-type' parameter is longer than all the others, so it
spoiled the spacing.  This commit just adds whitespace to make
everything look nice and aligned again.

I've added the --diff-content-type parameter; are the commits above acceptable?

@theory theory merged commit 0728080 into theory:master Aug 9, 2012

Yep, merged, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment