summaryrefslogtreecommitdiff
path: root/builtin/difftool.c
diff options
context:
space:
mode:
authorLibravatar Jeff King <peff@peff.net>2020-07-28 16:26:31 -0400
committerLibravatar Junio C Hamano <gitster@pobox.com>2020-07-28 15:02:18 -0700
commitf6d8942b1fc6c968980c8ae03054d7b2114b4415 (patch)
treeded3f10f7d390a4dba264c70197b00bc327fae40 /builtin/difftool.c
parentstrvec: convert remaining callers away from argv_array name (diff)
downloadtgif-f6d8942b1fc6c968980c8ae03054d7b2114b4415.tar.xz
strvec: fix indentation in renamed calls
Code which split an argv_array call across multiple lines, like: argv_array_pushl(&args, "one argument", "another argument", "and more", NULL); was recently mechanically renamed to use strvec, which results in mis-matched indentation like: strvec_pushl(&args, "one argument", "another argument", "and more", NULL); Let's fix these up to align the arguments with the opening paren. I did this manually by sifting through the results of: git jump grep 'strvec_.*,$' and liberally applying my editor's auto-format. Most of the changes are of the form shown above, though I also normalized a few that had originally used a single-tab indentation (rather than our usual style of aligning with the open paren). I also rewrapped a couple of obvious cases (e.g., where previously too-long lines became short enough to fit on one), but I wasn't aggressive about it. In cases broken to three or more lines, the grouping of arguments is sometimes meaningful, and it wasn't worth my time or reviewer time to ponder each case individually. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/difftool.c')
-rw-r--r--builtin/difftool.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/builtin/difftool.c b/builtin/difftool.c
index 40c4d7b6b6..5ac021a1d4 100644
--- a/builtin/difftool.c
+++ b/builtin/difftool.c
@@ -211,9 +211,9 @@ static void changed_files(struct hashmap *result, const char *index_path,
env[0] = index_env.buf;
strvec_pushl(&update_index.args,
- "--git-dir", git_dir, "--work-tree", workdir,
- "update-index", "--really-refresh", "-q",
- "--unmerged", NULL);
+ "--git-dir", git_dir, "--work-tree", workdir,
+ "update-index", "--really-refresh", "-q",
+ "--unmerged", NULL);
update_index.no_stdin = 1;
update_index.no_stdout = 1;
update_index.no_stderr = 1;
@@ -226,8 +226,8 @@ static void changed_files(struct hashmap *result, const char *index_path,
run_command(&update_index);
strvec_pushl(&diff_files.args,
- "--git-dir", git_dir, "--work-tree", workdir,
- "diff-files", "--name-only", "-z", NULL);
+ "--git-dir", git_dir, "--work-tree", workdir,
+ "diff-files", "--name-only", "-z", NULL);
diff_files.no_stdin = 1;
diff_files.git_cmd = 1;
diff_files.use_shell = 0;
@@ -394,7 +394,7 @@ static int run_dir_diff(const char *extcmd, int symlinks, const char *prefix,
child.dir = prefix;
child.out = -1;
strvec_pushl(&child.args, "diff", "--raw", "--no-abbrev", "-z",
- NULL);
+ NULL);
for (i = 0; i < argc; i++)
strvec_push(&child.args, argv[i]);
if (start_command(&child))