HAMMER - Implement volume-list command
[dragonfly.git] / sbin / hammer / hammer.c
index 80eedb0..88b51c4 100644 (file)
@@ -416,6 +416,14 @@ main(int ac, char **av)
                        usage(1);
                exit(0);
        }
+       if (strcmp(av[0], "dedup-simulate") == 0) {
+               hammer_cmd_dedup_simulate(av + 1, ac - 1);
+               exit(0);
+       }
+       if (strcmp(av[0], "dedup") == 0) {
+               hammer_cmd_dedup(av + 1, ac - 1);
+               exit(0);
+       }
        if (strcmp(av[0], "version") == 0) {
                hammer_cmd_get_version(av + 1, ac - 1);
                exit(0);
@@ -432,6 +440,10 @@ main(int ac, char **av)
                hammer_cmd_volume_del(av + 1, ac - 1);
                exit(0);
        }
+       if (strcmp(av[0], "volume-list") == 0) {
+               hammer_cmd_volume_list(av + 1, ac - 1);
+               exit(0);
+       }
 
        uuid_name_lookup(&Hammer_FSType, "DragonFly HAMMER", &status);
        if (status != uuid_s_ok) {
@@ -569,6 +581,7 @@ usage(int exit_code)
                "hammer version-upgrade <filesystem> <version> [force]\n"
                "hammer volume-add <device> <filesystem>\n"
                "hammer volume-del <device> <filesystem>\n"
+               "hammer volume-list <filesystem>\n"
        );
 
        fprintf(stderr, "\nHAMMER utility version 3+ commands:\n");
@@ -595,6 +608,13 @@ usage(int exit_code)
                "hammer -f blkdevs recover <target_dir>\n"
        );
 
+       fprintf(stderr, "\nHAMMER utility version 5+ commands:\n");
+
+       fprintf(stderr,
+               "hammer dedup-simulate <filesystem>\n"
+               "hammer dedup <filesystem>\n"
+       );
+
        exit(exit_code);
 }