aboutsummaryrefslogtreecommitdiff
path: root/main.c
diff options
context:
space:
mode:
authorgrunfink <grunfink@comam.es>2025-09-07 08:03:38 +0200
committergrunfink <grunfink@comam.es>2025-09-07 08:03:38 +0200
commitc541296f25f2c67bbefe5a9a93c5ee6e20ef7012 (patch)
tree63f533cccdaeb05c49fc52d43f32cc05dda237ac /main.c
parentfdcd7b953aacd31ad32e51317ed70962b76784df (diff)
New command-line option 'fsck'.
Diffstat (limited to 'main.c')
-rw-r--r--main.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/main.c b/main.c
index f767355..19cfe1a 100644
--- a/main.c
+++ b/main.c
@@ -34,6 +34,7 @@ int usage(const char *cmd)
"httpd {basedir} Starts the HTTPD daemon\n"
"purge {basedir} Purges old data\n"
"state {basedir} Prints server state\n"
+ "fsck {basedir} Performs a non-destructive data integrity check\n"
"webfinger {basedir} {account} Queries about an account (@user@host or actor url)\n"
"queue {basedir} {uid} Processes a user queue\n"
"follow {basedir} {uid} {actor} Follows an actor\n"
@@ -200,6 +201,11 @@ int main(int argc, char *argv[])
return 0;
}
+ if (strcmp(cmd, "fsck") == 0) { /** **/
+ data_fsck();
+ return 0;
+ }
+
if ((user = GET_ARGV()) == NULL)
return usage(cmd);