[ << ] | [ < ] | [ Up ] | [ > ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
7.4 The (ice-9 getopt-long) Module
The (ice-9 getopt-long)
module exports two procedures:
getopt-long
and option-ref
.
-
getopt-long
takes a list of strings — the command line arguments — an option specification, and some optional keyword parameters. It parses the command line arguments according to the option specification and keyword parameters, and returns a data structure that encapsulates the results of the parsing. -
option-ref
then takes the parsed data structure and a specific option’s name, and returns information about that option in particular.
To make these procedures available to your Guile script, include the
expression (use-modules (ice-9 getopt-long))
somewhere near the
top, before the first usage of getopt-long
or option-ref
.
7.4.1 A Short getopt-long Example | A short getopt-long example. | |
7.4.2 How to Write an Option Specification | How to write an option specification. | |
7.4.3 Expected Command Line Format | The expected command line format. | |
7.4.4 Reference Documentation for getopt-long | Full documentation for getopt-long .
| |
7.4.5 Reference Documentation for option-ref | Full documentation for option-ref .
|
[ << ] | [ < ] | [ Up ] | [ > ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
This document was generated on April 20, 2013 using texi2html 5.0.