Skip to content
/ cmdline Public

A portable, re-entrant replacement for getopt_long().

Notifications You must be signed in to change notification settings

BR903/cmdline

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This is a getopt_long() replacement that I use when I'm writing code
that needs to be portable to non-Unix environments (i.e. Windows).

cmdline uses a different organization, making use of callbacks instead
of having a function invoked repeatedly. This permits the API to be
called recursively, e.g. if an init file is named explicitly in argv.

The code also provides an API for parsing a single string into
argc/argv values, allowing for such things as accepting multiple
arguments via an environment variable.

This code is free and unencumbered software released into the public
domain, and you are free to use, copy, modify, publish, distribute or
sell this software. In jurisdictions that recognize copyright laws,
any and all copyright interest in the software is dedicated to the
public domain, with the intent of relinquishing in perpetuity all
present and future rights to this software under copyright law. This
software is provided "as is", without warranty of any kind, express or
implied.

Brian Raiter
<breadbox@muppetlabs.com>

About

A portable, re-entrant replacement for getopt_long().

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages