#!/bin/env hy

"ghdl

Usage:
  ghdl
  ghdl (-f <repo> | --force <repo>)
  ghdl [-n | --dry-run]
  ghdl (-h | --help)
  ghdl (-v | --version)

Options:
  -h --help               Show this screen.
  -v --version            Show version.
  -n --dry-run            Don't download, just show plan.
  -f repo --force=repo    Force update a single repo.
"

(import [docopt [docopt]])
(import ghdl)

(when (= __name__ "__main__")
    (setv args (docopt __doc__ :version ghdl.__version__))
    (when (get args "--dry-run") (ghdl.set-dry))
    (when (setx repo (get args "--force")) (ghdl.set-single (.lower repo)))
    (ghdl.main))
