add the help

This commit is contained in:
tTh 2023-05-01 11:57:07 +02:00
parent 755eb65da3
commit 1fc4d7a05d

View File

@ -17,7 +17,12 @@ int verbosity = 0;
/* --------------------------------------------------------------------- */
void help(void)
{
printf("nothing to say...\n");
printf("### READ_OBJ 0X%X TALKING\n", getpid());
puts("usage:");
puts("\t-h\tthis help (use -v -h for more");
puts("\t-o fname\tfix the output filename");
puts("\t-v\tincrease verbosity");
exit(0);
}
/* --------------------------------------------------------------------- */
@ -49,9 +54,8 @@ while ((opt = getopt(argc, argv, "ho:v")) != -1) {
}
}
if (optind < argc) {
fprintf(stderr, "arg = %s\n", argv[optind]);
if (verbosity) fprintf(stderr, "arg[%d] = %s\n", optind, argv[optind]);
foo = try_to_read_an_OBJ_file(argv[optind], ofname, 0);
if (foo) {
fprintf(stderr, "Error number %d on '%s'\n", foo, argv[optind]);