implement command line options

This patch implements both long command line options, such as "--key"
and "--key value", and options read from a config file as key=value.
Merge pull request #8 from nichtich/cli

implement command line options