summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Mendler <mail@daniel-mendler.de>2023-08-20 17:43:42 +0200
committerDaniel Mendler <mail@daniel-mendler.de>2023-08-20 17:43:42 +0200
commit29b908f48e0fd5b85951bd6e73546ee833d64d59 (patch)
tree1726fe75e4144be8860380aa4767f892fc17a8fd
parent2112b05e02d045c8a69d18b992e85fc11e430456 (diff)
cape-elisp-block: Always complete when invoked interactively
-rw-r--r--README.org1
-rw-r--r--cape.el4
2 files changed, 4 insertions, 1 deletions
diff --git a/README.org b/README.org
index a8d0695..4078884 100644
--- a/README.org
+++ b/README.org
@@ -93,6 +93,7 @@ information.
("C-c p f" . cape-file)
("C-c p k" . cape-keyword)
("C-c p s" . cape-symbol)
+ ("C-c p e" . cape-elisp-block)
("C-c p a" . cape-abbrev)
("C-c p l" . cape-line)
("C-c p w" . cape-dict)
diff --git a/cape.el b/cape.el
index 7c9be7c..9a73b4c 100644
--- a/cape.el
+++ b/cape.el
@@ -478,7 +478,9 @@ This Capf is particularly useful for literate Emacs configurations.
If INTERACTIVE is nil the function acts like a Capf."
(interactive (list t))
(if interactive
- (cape-interactive #'cape-elisp-block)
+ ;; No code block check. Always complete Elisp when the command was
+ ;; explicitly invoked interactively.
+ (cape-interactive #'elisp-completion-at-point)
(when-let ((face (get-text-property (point) 'face))
(lang (or (and (if (listp face)
(memq 'org-block face)