From aaa86c4187942abc0869a133e917dbf32b95bb6b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs?= Date: Fri, 26 Oct 2018 23:27:56 -0500 Subject: =?UTF-8?q?single=20syntax=20with=20=C2=ABuse-package=C2=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lisp/init-php.el | 28 +++++++++++++--------------- 1 file changed, 13 insertions(+), 15 deletions(-) (limited to 'lisp/init-php.el') diff --git a/lisp/init-php.el b/lisp/init-php.el index 833707f..104d4c7 100644 --- a/lisp/init-php.el +++ b/lisp/init-php.el @@ -1,21 +1,19 @@ -(use-package php-mode) (use-package ac-php) -(autoload 'php-mode "php-mode" "Major mode for editing PHP code." t) -(add-to-list 'auto-mode-alist '("\\.php$" . php-mode)) -(add-to-list 'auto-mode-alist '("\\.inc$" . php-mode)) +(use-package php-mode + :mode (("\\.php$" . php-mode) + ("\\.inc$" . php-mode)) + :config + (add-hook 'php-mode-hook + '(lambda () + (auto-complete-mode t) + (require 'ac-php) + (setq ac-sources '(ac-source-php )) + (setq ac-sources '(ac-source-dictionary ac-source-abbrev ac-source-php )) -(add-hook 'php-mode-hook - '(lambda () - (auto-complete-mode t) - (require 'ac-php) - (setq ac-sources '(ac-source-php )) - (setq ac-sources '(ac-source-dictionary ac-source-abbrev ac-source-php )) - - (ac-php-core-eldoc-setup ) ;; enable eldoc - (define-key php-mode-map (kbd "C-]") 'ac-php-find-symbol-at-point) ;goto define - (define-key php-mode-map (kbd "C-t") 'ac-php-location-stack-back) ;go back - )) + (ac-php-core-eldoc-setup ) ;; enable eldoc + (define-key php-mode-map (kbd "C-]") 'ac-php-find-symbol-at-point) ;goto define + (define-key php-mode-map (kbd "C-t") 'ac-php-location-stack-back)))) ;go back (use-package smarty-mode) -- cgit v1.2.3