Skip to content

C++ replacement for the getopt family of command line option parsers

Notifications You must be signed in to change notification settings

goodfella/libgetopt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

libgetopt

Introduction

libgetopt is a C++ wrapper around the getopt family of functions provided by the GNU C library. Its purpose is to take the boiler plate code that is necessary when using the getopt functions and replace it with a simple easy to use interface for specifying and parsing command line options.

Options are specified to take an argument of a given C++ type. When parsing the command line, option arguments will be checked to insure that they meet the criteria necessary to assign them to the designated type for their respective option. For example if an option is designated to take an int, then libgetopt will check to insure that the argument specified for the option does not overflow or underflow an int, and is capable of being converted to an int.

libgetopt also provides overloads to handle options specified with user defined types. In addition, one can specify a custom parser of an option’s argument.

About

C++ replacement for the getopt family of command line option parsers

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published