changeset 689: |
2e7d93b892a5 |
parent: |
af486e0a40c9
|
author: |
Richard Westhaver <ellis@rwest.io> |
date: |
Tue, 01 Oct 2024 22:29:08 -0400 |
permissions: |
-rw-r--r-- |
description: |
cli shell tests init |
2 (:use :cl :std :sb-ext :cli :packy :clap :log)) 4 (in-package :bin/packy) 7 (defvar *pk-targets* nil) 8 (defopt pk-help (print-help *cli*)) 9 (defopt pk-version (print-version *cli*)) 10 (defopt pk-log-level (when *arg* (setq *log-level* :debug))) 11 (defopt pk-target (setq *pk-targets* *arg*)) 12 (defcmd pk-show (print (list *optc* *argc* *opts* *args* *pk-targets*))) 14 (define-cli *packy-cli* 17 :description "Universal Package Manager" 19 :opts ((:name "level" :description "set the log level" :thunk pk-log-level) 20 (:name "help" :description "print help" :thunk pk-help) 21 (:name "version" :description "print version" :thunk pk-version)) 23 :opts (:name "target" :thunk pk-target) 27 (let ((*log-level* :info)) 28 (with-cli (*packy-cli* opts cmds args) (cli:args) 32 (defmain start-packy () 33 (let ((*print-readably* t)) 35 (sb-ext:exit :code 0)))