feat: advancement on map parse
This commit is contained in:
parent
7321db26d9
commit
d586acba8f
11 changed files with 257 additions and 123 deletions
|
|
@ -6,7 +6,7 @@
|
|||
/* By: bgoulard <bgoulard@student.42.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2024/11/09 01:14:09 by bgoulard #+# #+# */
|
||||
/* Updated: 2024/11/09 01:37:41 by bgoulard ### ########.fr */
|
||||
/* Updated: 2024/11/15 09:03:03 by bgoulard ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
|
|
@ -19,21 +19,21 @@
|
|||
|
||||
int c3_options(t_info *info, int argc, char *argv[])
|
||||
{
|
||||
int parsed_args;
|
||||
int parsed_args;
|
||||
const t_opt opts[] = {
|
||||
{"file", 'f', c3_set_file, OPT_ARG | OPT_EQSIGN | OPT_OTHER},
|
||||
{"debug", 'd', c3_set_debug, 0},
|
||||
{"save", 's', c3_set_save, 0},
|
||||
{"help", 'h', c3_print_help, 0},
|
||||
{"file", 'f', c3_set_file, OPT_ARG | OPT_EQSIGN | OPT_OTHER},
|
||||
{"debug", 'd', c3_set_debug, 0},
|
||||
{"save", 's', c3_set_save, 0},
|
||||
{"help", 'h', c3_print_help, 0},
|
||||
// add more options here put the implementation in options_impl.c
|
||||
// if you want custom option see ft_args_types.h for more info
|
||||
// code example in it.
|
||||
{NULL, 0, NULL, 0}
|
||||
{NULL, 0, NULL, 0}
|
||||
};
|
||||
|
||||
(void)argc;
|
||||
ft_bzero(info, sizeof(t_info));
|
||||
ft_setup_prog((const char * const *)argv);
|
||||
ft_setup_prog((const char *const *)argv);
|
||||
ft_set_opt_list(opts);
|
||||
parsed_args = ft_parse_args((const char **)argv, &(info->cli_ctx));
|
||||
return (parsed_args);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue