summaryrefslogtreecommitdiff
path: root/generate-cmdlist.sh
diff options
context:
space:
mode:
authorJohannes Schindelin <johannes.schindelin@gmx.de>2016-06-22 15:01:28 (GMT)
committerJunio C Hamano <gitster@pobox.com>2016-06-24 20:50:45 (GMT)
commit6ea57703f660afd00159b67bf8749d90881df3b4 (patch)
tree65aaa4a2c882082c67c117a4f5008b23437d0a8f /generate-cmdlist.sh
parentab7797dbe95fff38d9265869ea367020046db118 (diff)
downloadgit-6ea57703f660afd00159b67bf8749d90881df3b4.zip
git-6ea57703f660afd00159b67bf8749d90881df3b4.tar.gz
git-6ea57703f660afd00159b67bf8749d90881df3b4.tar.bz2
log: prepare log/log-tree to reuse the diffopt.close_file attribute
We are about to teach the log-tree machinery to reuse the diffopt.file field to output to a file stream other than stdout, in line with the diff machinery already writing to diffopt.file. However, we might want to write something after the diff in log_tree_commit() (e.g. with the --show-linear-break option), therefore we must not let the diff machinery close the file (as per diffopt.close_file. This means that log_tree_commit() itself must override the diffopt.close_file flag and close the file, and if log_tree_commit() is called in a loop, the caller is responsible to do the same. Note: format-patch has an `--output-directory` option. Due to the fact that format-patch's options are parsed first, and that the parse-options machinery accepts uniquely abbreviated options, the diff options `--output` (and `-o`) are shadowed. Therefore close_file is not set to 1 so that cmd_format_patch() does *not* need to handle the close_file flag differently, even if it calls log_tree_commit() in a loop. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'generate-cmdlist.sh')
0 files changed, 0 insertions, 0 deletions