[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/inf-clojure 52f9404 016/313: Add apropos command
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/inf-clojure 52f9404 016/313: Add apropos command |
Date: |
Wed, 11 Aug 2021 09:59:37 -0400 (EDT) |
branch: elpa/inf-clojure
commit 52f940437524ed2dbde81869d796a3d125022fb1
Author: Bozhidar Batsov <bozhidar@batsov.com>
Commit: Bozhidar Batsov <bozhidar@batsov.com>
Add apropos command
---
inf-clojure.el | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/inf-clojure.el b/inf-clojure.el
index cfe7c4a..78a0d1a 100644
--- a/inf-clojure.el
+++ b/inf-clojure.el
@@ -100,6 +100,7 @@ mode. Default is whitespace followed by 0 or 1
single-letter colon-keyword
(define-key map "\C-c\C-v" 'clojure-show-var-documentation)
(define-key map "\C-c\C-s" 'clojure-show-var-source)
(define-key map "\C-c\C-i" 'clojure-show-ns-vars)
+ (define-key map "\C-c\C-A" 'clojure-apropos)
map))
;;;###autoload
@@ -401,6 +402,11 @@ Used by this command to determine defaults."
"(clojure.repl/dir %s)\n"
"Command to show the public vars in a namespace.")
+(defvar clojure-apropos-command
+ "(doseq [var (sort (clojure.repl/apropos \"%s\"))]
+ (println (str var)))\n"
+ "Command to invoke apropos.")
+
;;; Ancillary functions
;;; ===================
@@ -466,6 +472,12 @@ See variable `clojure-ns-vars-command'."
(interactive (clojure-symprompt "Ns vars" (clojure-find-ns)))
(comint-proc-query (inf-clojure-proc) (format clojure-ns-vars-command ns)))
+(defun clojure-apropos (var)
+ "Send a command to the inferior Clojure to give apropos for VAR.
+See variable `clojure-apropos-command'."
+ (interactive (clojure-symprompt "Var apropos" (clojure-var-at-pt)))
+ (comint-proc-query (inf-clojure-proc) (format clojure-apropos-command var)))
+
;; "Returns the current inferior Clojure process.
;; See variable `inf-clojure-buffer'."
- [nongnu] elpa/inf-clojure 898a319 041/313: Improve the README a bit, (continued)
- [nongnu] elpa/inf-clojure 898a319 041/313: Improve the README a bit, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure ff20773 044/313: Release 1.2.0, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 0652692 012/313: Preprocess the output from interactive commands, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 85d3d41 014/313: Extract a chomp helper, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure abb5a53 017/313: Add macroexpand command, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 3c2a1ed 022/313: Rename switch-to-clojure to inf-clojure-switch-to-repl, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure f00b2b5 026/313: Add a menu for inf-clojure-minor-mode, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 0d5f715 027/313: Unify the style of the REPL and minor mode menus, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 9a0323d 028/313: [Fix #4] Start subprocess in the root of lein and boot projects, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure b2d6d0e 009/313: Add a command to show a var's source, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 52f9404 016/313: Add apropos command,
ELPA Syncer <=
- [nongnu] elpa/inf-clojure ecf614e 018/313: Use inf-clojure prefix consistently, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 2627825 025/313: Move inf-clojure-mode menu definition, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure de88e4f 032/313: Solution to unresponsive repl in Windows OS, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure c3a9283 035/313: Use #' in the keymaps, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure c23e13a 040/313: Minor readability improvement, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 44f3f97 047/313: Improve a docstring, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 286b935 059/313: Release 1.3.0, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 6c18b2c 052/313: Remove a bit of legacy from inferior-lisp, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 6ccb53e 054/313: Fix a docstring, ELPA Syncer, 2021/08/11
- [nongnu] elpa/inf-clojure 98d324b 058/313: Merge pull request #19 from otijhuis/too-many-newlines, ELPA Syncer, 2021/08/11