format-patch: add --inline option and make --attach a true attachment
The existing --attach option did not create a true "attachment" but multipart/mixed with Content-Disposition: inline. It should have been with Content-Disposition: attachment. Introduce --inline to add multipart/mixed that is inlined, and make --attach to create an attachement. Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:

committed by
Junio C Hamano

parent
3ddad98b74
commit
c112f689c2
@ -205,10 +205,12 @@ void show_log(struct rev_info *opt, const char *sep)
|
||||
"Content-Type: text/x-patch;\n"
|
||||
" name=\"%s.diff\"\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Content-Disposition: inline;\n"
|
||||
"Content-Disposition: %s;\n"
|
||||
" filename=\"%s.diff\"\n\n",
|
||||
mime_boundary_leader, opt->mime_boundary,
|
||||
sha1, sha1);
|
||||
sha1,
|
||||
opt->no_inline ? "attachment" : "inline",
|
||||
sha1);
|
||||
opt->diffopt.stat_sep = buffer;
|
||||
}
|
||||
} else if (opt->commit_format != CMIT_FMT_USERFORMAT) {
|
||||
|
Reference in New Issue
Block a user