commit b17969ebd1ad9271caaddf6db9c103bb454446c4
parent 48088badbbcf452862391d6cc16bec3bbf7bce52
Author: hhvn <dev@hhvn.uk>
Date: Wed, 17 Nov 2021 00:55:01 +0000
main.c: document default value for config variables
Diffstat:
1 file changed, 6 insertions(+), 0 deletions(-)
diff --git a/main.c b/main.c
@@ -224,6 +224,12 @@ main(int argc, char *argv[]) {
for (i=0; config[i].name; i++) {
printf(".It %s\n", config[i].name);
printf(".Bd -literal -compact\n");
+ if (config[i].valtype == Val_string)
+ printf("Default value: %s\n", config[i].str);
+ else if (config[i].valtype == Val_pair || config[i].valtype == Val_colourpair)
+ printf("Default value: {%02ld, %02ld}\n", config[i].pair[0], config[i].pair[1]);
+ else
+ printf("Default value: %02ld\n", config[i].num);
for (j=0; config[i].description[j]; j++)
printf("%s\n", config[i].description[j]);
printf(".Ed\n");