summaryrefslogtreecommitdiff
path: root/builtin
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2010-05-21 04:02:16 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2010-05-21 04:02:16 -0700
commitcd4ce1e8a81ef5c24af7b914fb72212273e7d489 (patch)
treef92ec5eee5cf02b429ff9a9002b29e663e5eea38 /builtin
parentMerge branch 'np/malloc-threading' (diff)
parentwt-status: fix 'fprintf' compilation warning (diff)
downloadtgif-cd4ce1e8a81ef5c24af7b914fb72212273e7d489.tar.xz
Merge branch 'jc/status-show-ignored'
* jc/status-show-ignored: wt-status: fix 'fprintf' compilation warning status: --ignored option shows ignored files wt-status: rename and restructure status-print-untracked wt-status: collect ignored files wt-status: plug memory leak while collecting untracked files wt-status: remove unused workdir_untracked member
Diffstat (limited to 'builtin')
-rw-r--r--builtin/commit.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/builtin/commit.c b/builtin/commit.c
index 017b8a5536..ddf77e48e1 100644
--- a/builtin/commit.c
+++ b/builtin/commit.c
@@ -83,6 +83,7 @@ static enum {
static char *cleanup_arg;
static int use_editor = 1, initial_commit, in_merge, include_status = 1;
+static int show_ignored_in_status;
static const char *only_include_assumed;
static struct strbuf message;
@@ -1038,6 +1039,8 @@ int cmd_status(int argc, const char **argv, const char *prefix)
"mode",
"show untracked files, optional modes: all, normal, no. (Default: all)",
PARSE_OPT_OPTARG, NULL, (intptr_t)"all" },
+ OPT_BOOLEAN(0, "ignored", &show_ignored_in_status,
+ "show ignored files"),
OPT_END(),
};
@@ -1051,7 +1054,8 @@ int cmd_status(int argc, const char **argv, const char *prefix)
builtin_status_options,
builtin_status_usage, 0);
handle_untracked_files_arg(&s);
-
+ if (show_ignored_in_status)
+ s.show_ignored_files = 1;
if (*argv)
s.pathspec = get_pathspec(prefix, argv);