[emacs] Switch to company for auto-completion

This commit is contained in:
Correl Roush 2015-07-15 23:54:09 -04:00
parent 35ad37432c
commit 74e7bea32b

View file

@ -296,17 +296,31 @@ A strongly typed, pure functional language.
#+END_SRC #+END_SRC
** Tools ** Tools
*** Autocomplete *** Autocomplete
**** Company
Install and configure Company for auto-completion.
#+name: autocomplete #+name: autocomplete
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp
(use-package auto-complete (use-package company
:ensure t :ensure t
:config :config (progn
(progn (global-auto-complete-mode t) (add-hook 'prog-mode-hook 'company-mode)
(require 'auto-complete-config)
(ac-config-default) (bind-key "C-n" #'company-select-next company-active-map)
(ac-set-trigger-key "TAB") (bind-key "C-p" #'company-select-previous company-active-map)))
(ac-set-trigger-key "<tab>")))
#+END_SRC #+END_SRC
**** Auto-Complete
Not using this for auto-completion anymore, but several packages
require it.
#+name: autocomplete
#+begin_src emacs-lisp
(use-package auto-complete
:ensure t)
#+end_src
*** Flycheck *** Flycheck
#+name: packages #+name: packages
#+BEGIN_SRC emacs-lisp #+BEGIN_SRC emacs-lisp