diff options
| author | Junio C Hamano <gitster@pobox.com> | 2024-12-04 10:14:47 +0900 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2024-12-04 10:14:47 +0900 |
| commit | 1e18cf4310b531cd5d943b9f9522292e7cc4d9e7 (patch) | |
| tree | 5ecb42da0e9dd53ac0da0d2203207b3bef5caff2 /builtin/refs.c | |
| parent | 8c917be5d29c22d438a321baa585a87c026543b3 (diff) | |
| parent | 6f33d8e255cb2ff738cd28eab22751efb7c2d6ce (diff) | |
| download | git-1e18cf4310b531cd5d943b9f9522292e7cc4d9e7.tar.gz | |
Merge branch 'kn/pass-repo-to-builtin-sub-sub-commands'
Built-in Git subcommands are supplied the repository object to work
with; they learned to do the same when they invoke sub-subcommands.
* kn/pass-repo-to-builtin-sub-sub-commands:
builtin: pass repository to sub commands
Diffstat (limited to 'builtin/refs.c')
| -rw-r--r-- | builtin/refs.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/builtin/refs.c b/builtin/refs.c index 394b4101c6..a29f195834 100644 --- a/builtin/refs.c +++ b/builtin/refs.c @@ -13,7 +13,8 @@ #define REFS_VERIFY_USAGE \ N_("git refs verify [--strict] [--verbose]") -static int cmd_refs_migrate(int argc, const char **argv, const char *prefix) +static int cmd_refs_migrate(int argc, const char **argv, const char *prefix, + struct repository *repo UNUSED) { const char * const migrate_usage[] = { REFS_MIGRATE_USAGE, @@ -64,7 +65,8 @@ out: return err; } -static int cmd_refs_verify(int argc, const char **argv, const char *prefix) +static int cmd_refs_verify(int argc, const char **argv, const char *prefix, + struct repository *repo UNUSED) { struct fsck_options fsck_refs_options = FSCK_REFS_OPTIONS_DEFAULT; struct worktree **worktrees; @@ -99,7 +101,7 @@ static int cmd_refs_verify(int argc, const char **argv, const char *prefix) int cmd_refs(int argc, const char **argv, const char *prefix, - struct repository *repo UNUSED) + struct repository *repo) { const char * const refs_usage[] = { REFS_MIGRATE_USAGE, @@ -114,5 +116,5 @@ int cmd_refs(int argc, }; argc = parse_options(argc, argv, prefix, opts, refs_usage, 0); - return fn(argc, argv, prefix); + return fn(argc, argv, prefix, repo); } |
