summaryrefslogtreecommitdiff
path: root/fetch-pack.c
diff options
context:
space:
mode:
authorJeff King <peff@peff.net>2020-07-28 16:26:31 -0400
committerJunio C Hamano <gitster@pobox.com>2020-07-28 15:02:18 -0700
commitf6d8942b1fc6c968980c8ae03054d7b2114b4415 (patch)
treeded3f10f7d390a4dba264c70197b00bc327fae40 /fetch-pack.c
parentc972bf4cf546a56fe1c54ddde1d33ebb9f454a0f (diff)
downloadgit-f6d8942b1fc6c968980c8ae03054d7b2114b4415.tar.gz
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 'fetch-pack.c')
-rw-r--r--fetch-pack.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/fetch-pack.c b/fetch-pack.c
index 7aa5dfbdad..7f20eca4f8 100644
--- a/fetch-pack.c
+++ b/fetch-pack.c
@@ -854,8 +854,8 @@ static int get_pack(struct fetch_pack_args *args,
if (xgethostname(hostname, sizeof(hostname)))
xsnprintf(hostname, sizeof(hostname), "localhost");
strvec_pushf(&cmd.args,
- "--keep=fetch-pack %"PRIuMAX " on %s",
- (uintmax_t)getpid(), hostname);
+ "--keep=fetch-pack %"PRIuMAX " on %s",
+ (uintmax_t)getpid(), hostname);
}
if (only_packfile && args->check_self_contained_and_connected)
strvec_push(&cmd.args, "--check-self-contained-and-connected");
@@ -885,7 +885,7 @@ static int get_pack(struct fetch_pack_args *args,
if (pass_header)
strvec_pushf(&cmd.args, "--pack_header=%"PRIu32",%"PRIu32,
- ntohl(header.hdr_version),
+ ntohl(header.hdr_version),
ntohl(header.hdr_entries));
if (fetch_fsck_objects >= 0
? fetch_fsck_objects
@@ -901,7 +901,7 @@ static int get_pack(struct fetch_pack_args *args,
strvec_push(&cmd.args, "--fsck-objects");
else
strvec_pushf(&cmd.args, "--strict%s",
- fsck_msg_types.buf);
+ fsck_msg_types.buf);
}
cmd.in = demux.out;
@@ -1654,8 +1654,8 @@ static struct ref *do_fetch_pack_v2(struct fetch_pack_args *args,
strvec_push(&cmd.args, "http-fetch");
strvec_pushf(&cmd.args, "--packfile=%.*s",
- (int) the_hash_algo->hexsz,
- packfile_uris.items[i].string);
+ (int) the_hash_algo->hexsz,
+ packfile_uris.items[i].string);
strvec_push(&cmd.args, uri);
cmd.git_cmd = 1;
cmd.no_stdin = 1;