44 lines
665 B
Markdown
44 lines
665 B
Markdown
# cli.h
|
|
|
|
## Include Guard
|
|
```c
|
|
#ifndef CLI_H
|
|
# define CLI_H
|
|
|
|
# include <stdint.h>
|
|
```
|
|
|
|
## Types
|
|
|
|
### `t_args`
|
|
Struct to hold command-line arguments.
|
|
```c
|
|
typedef struct s_args
|
|
{
|
|
const char *ext;
|
|
const char *input;
|
|
const char *output;
|
|
const char *map_path;
|
|
uint8_t show_help;
|
|
} t_args;
|
|
```
|
|
## Functions
|
|
|
|
### [`cli_parse`](/srcs/cli/cli.c.md)
|
|
Parses command-line arguments and populates the t_args structure.
|
|
```c
|
|
int8_t
|
|
cli_parse(t_args *args, int32_t argc, char **argv);
|
|
```
|
|
|
|
### [`cli_print_help`](/srcs/cli/help.c.md)
|
|
Prints help information for the command-line interface.
|
|
```c
|
|
void
|
|
cli_print_help(const char *progname);
|
|
```
|
|
|
|
## End Guard
|
|
```c
|
|
#endif
|
|
```
|