Package gmisclib :: Module gpk_getopt
[frames] | no frames]

Module gpk_getopt

source code

Functions
 
parse(arglist, shortoptions, longoptions)
Splits apart an command line argument list, and puts the arguments into a dictionary.
source code
Variables
  __package__ = 'gmisclib'

Imports: getopt


Function Details

parse(arglist, shortoptions, longoptions)

source code 

Splits apart an command line argument list, and puts the arguments into a dictionary. The arguments are a list to be parsed, a string of short one character options, and a list of long gnu-style options. The function returns a dictionary mapping between option names and values (if any). Names in the dictionary have had leading dashes removed.