Created
January 6, 2015 09:36
-
-
Save snowleung/7d9cdc3065409dcc69ab to your computer and use it in GitHub Desktop.
my .emacs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(add-to-list 'load-path "~/.emacs.d/plugins/") | |
(require 'auto-complete-config) | |
(add-to-list 'ac-dictionary-directories "~/.emacs.d/plugins//ac-dict") | |
(ac-config-default) | |
(global-linum-mode 1) | |
(add-to-list 'load-path | |
"~/.emacs.d/plugins/yasnippet") | |
(require 'yasnippet) | |
(yas-global-mode 1) | |
;; FIX YASNIPPET AND AUTOCOMPLETE TAB KEY COLLISION | |
;; Remove Yasnippet's default tab key binding | |
(define-key yas-minor-mode-map (kbd "<tab>") nil) | |
(define-key yas-minor-mode-map (kbd "TAB") nil) | |
;; Set Yasnippet's key binding to shift+tab | |
(define-key yas-minor-mode-map (kbd "<backtab>") 'yas-expand) | |
(require 'auto-complete-config) | |
(add-to-list 'ac-dictionary-directories "~/.emacs.d/ac-dict") | |
(ac-config-default) | |
(global-auto-complete-mode t) | |
(ac-set-trigger-key "TAB") | |
(ac-set-trigger-key "<tab>") | |
;; (add-to-list 'load-path "~/.emacs.d/plugins/emmet-mode/") | |
;; (require 'emmet-mode) | |
(add-to-list 'load-path "~/.emacs.d/plugins/py-mode/") | |
(setq py-install-directory "~/.emacs.d/plugins/py-mode/") | |
(require 'python-mode) | |
;; (autoload 'python-mode "python-mode" "Python Mode." t) | |
;; (add-to-list 'auto-mode-alist '("\\.py\\'" . python-mode)) | |
;; (add-to-list 'interpreter-mode-alist '("python" . python-mode)) | |
(require 'web-mode) | |
;; (add-to-list 'auto-mode-alist '("\\.phtml\\'" . web-mode)) | |
;; (add-to-list 'auto-mode-alist '("\\.tpl\\.php\\'" . web-mode)) | |
;; (add-to-list 'auto-mode-alist '("\\.[agj]sp\\'" . web-mode)) | |
;; (add-to-list 'auto-mode-alist '("\\.as[cp]x\\'" . web-mode)) | |
;; (add-to-list 'auto-mode-alist '("\\.erb\\'" . web-mode)) | |
;; (add-to-list 'auto-mode-alist '("\\.mustache\\'" . web-mode)) | |
;; (add-to-list 'auto-mode-alist '("\\.djhtml\\'" . web-mode)) | |
(add-to-list 'auto-mode-alist '("\\.html?\\'" . web-mode)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment