diff options
Diffstat (limited to 'builtin/diff-index.c')
| -rw-r--r-- | builtin/diff-index.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/builtin/diff-index.c b/builtin/diff-index.c index 8bd5aa464b..81c0bc8ed7 100644 --- a/builtin/diff-index.c +++ b/builtin/diff-index.c @@ -1,10 +1,12 @@ +#define USE_THE_REPOSITORY_VARIABLE +#define DISABLE_SIGN_COMPARE_WARNINGS + #include "builtin.h" #include "config.h" #include "diff.h" #include "diff-merges.h" #include "commit.h" #include "preload-index.h" -#include "repository.h" #include "revision.h" #include "setup.h" @@ -14,15 +16,17 @@ static const char diff_cache_usage[] = "\n" COMMON_DIFF_OPTIONS_HELP; -int cmd_diff_index(int argc, const char **argv, const char *prefix) +int cmd_diff_index(int argc, + const char **argv, + const char *prefix, + struct repository *repo UNUSED) { struct rev_info rev; unsigned int option = 0; int i; int result; - if (argc == 2 && !strcmp(argv[1], "-h")) - usage(diff_cache_usage); + show_usage_if_asked(argc, argv, diff_cache_usage); git_config(git_diff_basic_config, NULL); /* no "diff" UI options */ |
