Code

git: browsing paths with spaces when using the start command
[git.git] / builtin-ls-files.c
index 88e2697aebf11399baf9f9c8b5a63b06a0f83c1d..2312866605c4140ac4e5a9f5bb963ca5ab5c6da3 100644 (file)
@@ -454,7 +454,7 @@ int cmd_ls_files(int argc, const char **argv, const char *prefix)
                OPT_BIT(0, "directory", &dir.flags,
                        "show 'other' directories' name only",
                        DIR_SHOW_OTHER_DIRECTORIES),
-               OPT_BIT(0, "no-empty-directory", &dir.flags,
+               OPT_NEGBIT(0, "empty-directory", &dir.flags,
                        "don't show empty directories",
                        DIR_HIDE_EMPTY_DIRECTORIES),
                OPT_BOOLEAN('u', "unmerged", &show_unmerged,
@@ -486,7 +486,7 @@ int cmd_ls_files(int argc, const char **argv, const char *prefix)
                prefix_offset = strlen(prefix);
        git_config(git_default_config, NULL);
 
-       argc = parse_options(argc, argv, builtin_ls_files_options,
+       argc = parse_options(argc, argv, prefix, builtin_ls_files_options,
                        ls_files_usage, 0);
        if (show_tag || show_valid_bit) {
                tag_cached = "H ";
@@ -512,7 +512,7 @@ int cmd_ls_files(int argc, const char **argv, const char *prefix)
 
        pathspec = get_pathspec(prefix, argv);
 
-       /* be nice with submodule patsh ending in a slash */
+       /* be nice with submodule paths ending in a slash */
        read_cache();
        if (pathspec)
                strip_trailing_slash_from_submodules();