summaryrefslogtreecommitdiff
path: root/settings/setup-company-mode.el
blob: 61ee053cdfbe024495116d5f961a9dbcafb9810d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
;;; setup-company-mode.el --- company mode config    -*- lexical-binding: t; -*-

;;; Commentary:

;; basic company mode configs

;;; Code:
(require 'company)
(require 'company-lsp)

;; When working with a larger project, until a parser is written
;; for compile_commands.json DB, you can add the headers to
;; .dir-locals.el as follows:
;; (company-clang-arguments . ("-I/path/to/include"))

(setq company-idle-delay 0.1)
(setq company-clang-executable "/usr/bin/clang++")

(push 'company-lsp company-backends)
(add-hook 'after-init-hook 'global-company-mode)

(provide 'setup-company-mode)
;;; setup-company-mode.el ends here