Thanks for reviewing that.  I responded to your comments.  Not sure how to
proceed, so maybe you can elaborate or we can pair on it later or something.


On Fri, Feb 15, 2013 at 1:35 PM, Nick Lewis <notifications@github.com>wrote:

> In src/com/puppetlabs/utils.clj:
>
> > @@ -403,6 +403,29 @@
> >
> >  ;; ## Command-line parsing
> >
> > +(defn validate-cli-args!
> > +  "Validates that required command-line arguments are present.  If they are not,
> > +  exits with an error and displays usage information.
> > +
> > +  Also checks to see whether user has passed the `--help` flag, and if so, displays
> > +  the help and exits."
> > +  [args specs required-args]
> > +  (let [specs                   (conj specs
> > +                                  ["-h" "--help" "Show help" :default false :flag true])
> > +        [options extras banner] (apply cli/cli args specs)]
> > +    (when (:help options)
> > +      (println banner)
> > +      (System/exit 0))
> > +    (let [required-pairs (select-keys options required-args)]
> > +      (when-let [missing-field (some #(if (nil? (val %)) (key %)) required-pairs)]
>
> This code seems a little weird, but I'm not exactly sure how to improve it.
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/puppetlabs/puppetdb/pull/433/files#r3035768>.
>
>