summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaciej Barć <xgqt@gentoo.org>2022-08-17 00:16:33 +0200
committerMaciej Barć <xgqt@gentoo.org>2022-08-17 00:16:33 +0200
commitf40b7d38a472395dac81808ab3ff57a0119c5ebc (patch)
tree39cdf1067179328436130c5e219d13602f76ee1f
parentcompany-ebuild.el: / hack (diff)
downloadcompany-ebuild-f40b7d38a472395dac81808ab3ff57a0119c5ebc.tar.gz
company-ebuild-f40b7d38a472395dac81808ab3ff57a0119c5ebc.tar.bz2
company-ebuild-f40b7d38a472395dac81808ab3ff57a0119c5ebc.zip
company-ebuild.el: do not require a match
Signed-off-by: Maciej Barć <xgqt@gentoo.org>
-rw-r--r--company-ebuild.el15
1 files changed, 9 insertions, 6 deletions
diff --git a/company-ebuild.el b/company-ebuild.el
index 8ef299d..65c5aef 100644
--- a/company-ebuild.el
+++ b/company-ebuild.el
@@ -228,10 +228,6 @@ COMMAND is matched with `cl-case'.
ARG is the completion argument for annotation and candidates."
(interactive (list 'interactive))
(cl-case command
- (interactive
- (company-begin-backend 'company-ebuild))
- (prefix
- (and (eq major-mode 'ebuild-mode) (company-grab-symbol)))
(annotation
(company-ebuild--annotation arg))
(candidates
@@ -240,7 +236,13 @@ ARG is the completion argument for annotation and candidates."
(string-prefix-p arg candidate t))
(append company-ebuild--constant-keywords
(company-ebuild--dynamic-keywords)
- (company-ebuild--executables arg))))))
+ (company-ebuild--executables arg))))
+ (interactive
+ (company-begin-backend 'company-ebuild))
+ (prefix
+ (and (eq major-mode 'ebuild-mode) (company-grab-symbol)))
+ (require-match
+ nil)))
;;;###autoload
(defun company-ebuild-setup ()
@@ -266,7 +268,8 @@ or `require' Company-Ebuild:
(t
(add-to-list 'company-backends 'company-ebuild)))
;; Because some completions have length 1:
- (setq-local company-minimum-prefix-length 1))
+ (setq-local company-minimum-prefix-length 1)
+ (setq-local company-require-match nil))
;;;###autoload
(add-hook 'ebuild-mode-hook 'company-ebuild-setup)