-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathweb-completion-data.el
63 lines (49 loc) · 2.3 KB
/
web-completion-data.el
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
;;; web-completion-data.el --- Shared completion data for ac-html and company-web
;; Copyright (C) 2015 Zhang Kai Yu, Olexandr Sydorchuk
;; Author: Olexandr Sydorchuk <[email protected]>
;; Version: 0.2
;; Keywords: html, auto-complete, company
;; URL: https://github.com/osv/web-completion-data
;; This program is free software; you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or
;; (at your option) any later version.
;; This program is distributed in the hope that it will be useful,
;; but WITHOUT ANY WARRANTY; without even the implied warranty of
;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
;; along with this program. If not, see <http://www.gnu.org/licenses/>.
;;; Commentary:
;; This is just dependency for ac-html, company-web
;;
;; `web-completion-data-sources' is pair list of framework-name and directory of completion data
;;
;; This package provide default "html" completion data.
;;
;; Completion data directory structure:
;;
;; html-attributes-complete - attribute completion
;; html-attributes-list - attributes of tags-add-tables
;; html-attributes-short-docs - attributes documantation
;; html-tag-short-docs - tags documantation
;; If you decide extend with own completion data, let say "Bootstrap" data:
;;
;; (unless (assoc "Bootstrap" web-completion-data-sources)
;; (setq web-completion-data-sources
;; (cons (cons "Bootstrap" "/path/to/complete/data")
;; web-completion-data-sources)))
;;; Code:
(defconst web-completion-data-package-dir
(file-name-directory (or load-file-name (buffer-file-name)))
"The directory where `web-completion-data' package exists.")
(defconst web-completion-data-html-source-dir
(expand-file-name "html-stuff" web-completion-data-package-dir)
"The directory where basic completion source of `web-completion-data' exists.")
(defcustom web-completion-data-sources
'(("html" . web-completion-data-html-source-dir))
"Alist of source directories.
car is source name, cdr is source location."
:type 'alist)
(provide 'web-completion-data)
;;; web-completion-data.el ends here