diff options
author | Galin Simeonov <gts@volconst.com> | 2021-09-25 23:15:21 +0300 |
---|---|---|
committer | Galin Simeonov <gts@volconst.com> | 2021-09-25 23:15:21 +0300 |
commit | 7211f9c57204dc3b27327fc92352d99ad080a8db (patch) | |
tree | b154155aa4aa1c24817fcd062db3679767568845 /system_part.h | |
parent | 9868bd4ae045aadeb5cd9af6a13231462948077e (diff) | |
download | volgit-7211f9c57204dc3b27327fc92352d99ad080a8db.tar.gz |
made it create a directory with files containing the output of the program
Diffstat (limited to 'system_part.h')
-rw-r--r-- | system_part.h | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/system_part.h b/system_part.h new file mode 100644 index 0000000..ac06166 --- /dev/null +++ b/system_part.h @@ -0,0 +1,32 @@ +#ifndef VOLGIT_SYSTEM_PART_H +#define VOLGIT_SYSTEM_PART_H VOLGIT_SYSTEM_PART_H +#include <stdio.h> +#include <stdlib.h> +#include <unistd.h> +#include <sys/stat.h> +#include <fcntl.h> +#include <stdarg.h> + +extern const char *default_header; +extern const char *default_footer; + +extern struct Volgit_Options +{ + const char *input_path; + const char *output_path; + const char *header; + const char *footer; + int output_dir_fd; +}options; + +void die(const char *format, ...); + +void parse_options(int argc,char **argv); +char* read_file(const char *filename); +int create_branch_dir(const char *branch_name); +FILE* create_file(int branch_dir,const char *filename); +int create_files_dir(int branch_dir); +int create_diff_dir(int branch_dir); + + +#endif |