Lazy-load company-mode
This commit is contained in:
parent
92482309fc
commit
e21607f567
3 changed files with 18 additions and 8 deletions
|
@ -54,7 +54,9 @@
|
|||
(defun doom/company-complete ()
|
||||
"Bring up the completion popup. If there is only one result, auto-complete it."
|
||||
(interactive)
|
||||
(when (and (company-manual-begin)
|
||||
(require 'company)
|
||||
(when (and (bound-and-true-p company-mode)
|
||||
(company-manual-begin)
|
||||
(= company-candidates-length 1))
|
||||
(company-complete-common)))
|
||||
|
||||
|
|
|
@ -10,6 +10,7 @@
|
|||
(quoted (eq (car-safe backends) 'quote)))
|
||||
`(progn
|
||||
(defun ,def-name ()
|
||||
(require 'company)
|
||||
(set (make-local-variable 'company-backends)
|
||||
(append '((,@(mapcar (lambda (backend)
|
||||
(if quoted
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue