Skip to content

Commit

Permalink
prepare uninstall
Browse files Browse the repository at this point in the history
  • Loading branch information
jcs090218 committed Oct 23, 2024
1 parent cb581ad commit 46b7078
Show file tree
Hide file tree
Showing 4 changed files with 64 additions and 0 deletions.
33 changes: 33 additions & 0 deletions cmds/core/uninstall.lisp
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
;;;; cmds/core/uninstall.lisp --- Build executable

;;; Commentary
;;
;; The `uninstall' command definition.
;;

;;; Code

(defpackage qob-cli/uninstall
(:use cl)
(:export command))

(in-package :qob-cli/uninstall)

(defun options ()
"Options for `uninstall' command."
(list ))

(defun handler (cmd)
"Handler for `uninstall' command."
(qob-cli:call-script "core/uninstall" cmd))

(defun command ()
"The `uninstall' command."
(clingon:make-command
:name "uninstall"
:description "Uninstall packages"
:usage "[names..]"
:options (options)
:handler #'handler))

;;; End of cmds/core/uninstall.lisp
1 change: 1 addition & 0 deletions cmds/qob.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@
,(qob-cli/dists:command)
,(qob-cli/install:command)
,(qob-cli/install-deps:command)
,(qob-cli/uninstall:command)
,(qob-cli/list:command))))

;;; End of cmds/qob.lisp
29 changes: 29 additions & 0 deletions lisp/core/uninstall.lisp
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
;;;; lisp/core/uninstall.lisp --- Uninstall systems

;;; Commentary
;;
;; Command use to uninstall systems,
;;
;; $ qob uninstall [names..]
;;
;;
;; Optional arguments:
;;
;; [names..] name of the system(s) to uninstall
;;

;;; Code

(qob-init-ql)

(qob-load "shared")

(let ((names qob-args))
(cond ((zerop (length names))
(qob-help "core/uninstall"))
(t
;; TODO: ..
;;(qob-install-systems names)
)))

;;; End of lisp/core/uninstall.lisp
1 change: 1 addition & 0 deletions qob-cli.asd
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
(:file "cmds/core/dists")
(:file "cmds/core/install")
(:file "cmds/core/install-deps")
(:file "cmds/core/uninstall")
(:file "cmds/core/list")
(:file "cmds/qob")
;; Program
Expand Down

0 comments on commit 46b7078

Please sign in to comment.