#! /bin/sh # This source code is released into the public domain. # Parse command-line arguments. args=$(getopt c:v $*) if [ $? -ne 0 ]; then exit 1 fi set -- $args _uacme_flags="" while :; do case "$1" in -c) _CONFDIR="$2" shift; shift;; -v) LFACME_VERBOSE=1 shift;; -y) _uacme_flags="$_uacme_flags $1" shift;; --) shift; break;; esac done # Initialise. . __LIBDIR__/init.sh # Run the command. _command="$1"; shift if [ -z "$command" ]; then _fatal "missing command" fi _cscript="__LIBDIR__/command/${_command}.sh" if ! [ -x "$_cscript" ]; then _fatal "unknown command: %s" "$_command" fi . "$_cscript"