diff options
Diffstat (limited to 'fish/fish.c')
-rw-r--r-- | fish/fish.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/fish/fish.c b/fish/fish.c index da2d6d21..e66880f2 100644 --- a/fish/fish.c +++ b/fish/fish.c @@ -102,6 +102,7 @@ usage (void) " -h|--cmd-help List available commands\n" " -h|--cmd-help cmd Display detailed help on 'cmd'\n" " -a|--add image Add image\n" + " -D|--no-dest-paths Don't tab-complete paths from guest fs\n" " -m|--mount dev[:mnt] Mount dev on mnt (if omitted, /)\n" " -n|--no-sync Don't autosync\n" " -r|--ro Mount read-only\n" @@ -119,6 +120,7 @@ main (int argc, char *argv[]) { "cmd-help", 2, 0, 'h' }, { "help", 0, 0, '?' }, { "mount", 1, 0, 'm' }, + { "no-dest-paths", 0, 0, 'D' }, { "no-sync", 0, 0, 'n' }, { "ro", 0, 0, 'r' }, { "verbose", 0, 0, 'v' }, @@ -178,6 +180,10 @@ main (int argc, char *argv[]) drvs = drv; break; + case 'D': + complete_dest_paths = 0; + break; + case 'h': if (optarg) display_command (optarg); @@ -694,6 +700,16 @@ free_strings (char **argv) free (argv); } +int +count_strings (char * const * const argv) +{ + int c; + + for (c = 0; argv[c]; ++c) + ; + return c; +} + void print_strings (char * const * const argv) { |