argtable / argtable3

A single-file, ANSI C, command-line parsing library that parses GNU-style command-line options.
http://www.argtable.org
Other
372 stars 65 forks source link

Expose arg_basename function as part of the API #91

Closed antoniovazquezblanco closed 7 months ago

antoniovazquezblanco commented 7 months ago

Given that arg_basename is used internally in arg_file, I was wondering if it would make sense to expose it to the user.

One simple but common use would be to substitute progname with arg_basename(argv[0]).

Thanks

tomghuang commented 7 months ago

@antoniovazquezblanco : I use the cwalk library (https://likle.github.io/cwalk/reference/) to do these path operations. It is a single-file library, which is as easy to use as argtable3.

antoniovazquezblanco commented 7 months ago

Thanks!