Skip to content

Commit

Permalink
query lqn symbols from terminal
Browse files Browse the repository at this point in the history
  • Loading branch information
inconvergent committed May 4, 2024
1 parent d1202a8 commit 48184ad
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions bin/qnq-sh.lisp
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
(ql:quickload :lqn :silent t)
(in-package :lqn)

; TODO: this is incomplete

(lqn:qry (cdr (find :export (lqn:dat-read-one (lqn::internal-path-string "src/packages.lisp"))
:key (lambda (k) (and (listp k) (car k)))))
[(lqn:isub? (str! _) (lqn:sdwn (second (cmd-args))))]
#((lqn:out (lqn::desc (lqn::psymb :lqn _)))))

; (defun xqn/run (opts fx)
; (declare (optimize speed) (function fx))
; (sh/out :txt opts (sh/execute-qry fx nil ":pipe:" 0)))

; (sh/run-from-shell (format nil
; "██ QNQ - QUERY LQN SYMBOLS

; Usage:
; qnq <qry>

; Example:

; qnq 'msym'
; " (lqn:v?)) (cdr (cmd-args)) #'xqn/run #'xqn/run t)

0 comments on commit 48184ad

Please sign in to comment.