From 7a7159ace6c93ea6c55086dfc7ba7533a3e3c07d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Thu, 1 Mar 2012 13:26:42 +0100 Subject: merge --stat: use the full terminal width MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Make merge --stat behave like diff --stat and use the full terminal width. Signed-off-by: Zbigniew Jędrzejewski-Szmek Signed-off-by: Junio C Hamano --- builtin/merge.c | 1 + 1 file changed, 1 insertion(+) (limited to 'builtin/merge.c') diff --git a/builtin/merge.c b/builtin/merge.c index b4fbc60e6..b1cd90ccc 100644 --- a/builtin/merge.c +++ b/builtin/merge.c @@ -399,6 +399,7 @@ static void finish(struct commit *head_commit, if (new_head && show_diffstat) { struct diff_options opts; diff_setup(&opts); + opts.stat_width = -1; /* use full terminal width */ opts.output_format |= DIFF_FORMAT_SUMMARY | DIFF_FORMAT_DIFFSTAT; opts.detect_rename = DIFF_DETECT_RENAME; -- cgit v1.2.1 From df44483a5dde62f4b49c80fd90d7fe12ddcfb084 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Thu, 1 Mar 2012 13:26:46 +0100 Subject: diff --stat: add config option to limit graph width MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Config option diff.statGraphWidth= is equivalent to --stat-graph-width=, except that the config option is ignored by format-patch. For the graph-width limiting to be usable, it should happen 'automatically' once configured, hence the config option. Nevertheless, graph width limiting only makes sense when used on a wide terminal, so it should not influence the output of format-patch, which adheres to the 80-column standard. Signed-off-by: Zbigniew Jędrzejewski-Szmek Signed-off-by: Junio C Hamano --- builtin/merge.c | 1 + 1 file changed, 1 insertion(+) (limited to 'builtin/merge.c') diff --git a/builtin/merge.c b/builtin/merge.c index b1cd90ccc..34a5034a7 100644 --- a/builtin/merge.c +++ b/builtin/merge.c @@ -400,6 +400,7 @@ static void finish(struct commit *head_commit, struct diff_options opts; diff_setup(&opts); opts.stat_width = -1; /* use full terminal width */ + opts.stat_graph_width = -1; /* respect statGraphWidth config */ opts.output_format |= DIFF_FORMAT_SUMMARY | DIFF_FORMAT_DIFFSTAT; opts.detect_rename = DIFF_DETECT_RENAME; -- cgit v1.2.1