summaryrefslogtreecommitdiffstats
path: root/test/compose-all-in-dir.c
diff options
context:
space:
mode:
authorsijanec <sijanecantonluka@gmail.com>2020-05-17 00:01:46 +0200
committersijanec <sijanecantonluka@gmail.com>2020-05-17 00:01:46 +0200
commit1d4d0aae92057cba8137c8fd5d733b3fa59071f1 (patch)
treeba9f6e7863769891199df496cb3ec6b529a002cd /test/compose-all-in-dir.c
parentcritical OOM bug fix (diff)
downloadbverbose-1d4d0aae92057cba8137c8fd5d733b3fa59071f1.tar
bverbose-1d4d0aae92057cba8137c8fd5d733b3fa59071f1.tar.gz
bverbose-1d4d0aae92057cba8137c8fd5d733b3fa59071f1.tar.bz2
bverbose-1d4d0aae92057cba8137c8fd5d733b3fa59071f1.tar.lz
bverbose-1d4d0aae92057cba8137c8fd5d733b3fa59071f1.tar.xz
bverbose-1d4d0aae92057cba8137c8fd5d733b3fa59071f1.tar.zst
bverbose-1d4d0aae92057cba8137c8fd5d733b3fa59071f1.zip
Diffstat (limited to '')
-rw-r--r--test/compose-all-in-dir.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/test/compose-all-in-dir.c b/test/compose-all-in-dir.c
index 489891b..8805b0d 100644
--- a/test/compose-all-in-dir.c
+++ b/test/compose-all-in-dir.c
@@ -6,14 +6,17 @@
#include <string.h>
#include <limits.h>
extern int main(int argc, char* argv[]) {
- if(argc != 3) {
- printf("usage: %s source-dir/ destination-dir/ (trailing slash mandatory)\n", argv[0]);
+ if(argc != 3 && argc != 4) {
+ printf("usage: %s source-dir/ destination-dir/ [destination .extension=.html]\n", argv[0]);
return 1;
}
+ char* destination_extension = ".html";
+ if(argc == 4) {
+ destination_extension = argv[3];
+ }
char* source_folder_name = argv[1];
char* destination_folder_name = argv[2];
char* file_extension = ".bvr";
- char* destination_extension = ".html";
char* file_extension2 = ".bverbose"; // unofficial
char source_filename[NAME_MAX];
char destination_filename[NAME_MAX];