General cleanup

This commit is contained in:
Henrik Lissner
2016-04-16 21:27:59 -04:00
parent 0db56ccdb4
commit 87c2dc84f6
11 changed files with 69 additions and 65 deletions

View File

@@ -8,9 +8,8 @@
(associate! ansible-mode :in (yaml-mode) :files ("roles/"))
(use-package company-ansible
:defer t
:init
(define-company-backend! ansible-mode (ansible)))
:commands (company-ansible)
:init (define-company-backend! ansible-mode (ansible)))
(provide 'module-ansible)
;;; module-ansible.el ends here

View File

@@ -1,4 +1,4 @@
;;; module-cc.el
;;; module-cc.el --- C, C++, and Objective-C
(use-package cmake-mode
:mode "CMakeLists\\.txt$"
@@ -13,11 +13,11 @@
(use-package cc-mode
:defines (c-syntactic-context)
:functions (c-toggle-electric-state c-toggle-auto-newline
c-skip-comments-and-strings c-forward-sws c-end-of-macro
c-font-lock-invalid-string csharp-log c-font-lock-declarators
c-get-lang-constant c-forward-keyword-clause
c-fontify-recorded-types-and-refs c-forward-type imenu--split
c-backward-sws c-determine-limit c-beginning-of-decl-1)
c-skip-comments-and-strings c-forward-sws c-end-of-macro
c-font-lock-invalid-string csharp-log c-font-lock-declarators
c-get-lang-constant c-forward-keyword-clause
c-fontify-recorded-types-and-refs c-forward-type imenu--split
c-backward-sws c-determine-limit c-beginning-of-decl-1)
:commands (c-mode c++-mode objc-mode java-mode)
:init
(associate! objc-mode :match "\\.mm$")
@@ -81,8 +81,7 @@
(define-company-backend! c++-mode (irony))
(define-company-backend! objc-mode (irony))
;; This is necessary because c-mode dervied modes like php-mode may wrongfully trigger
;; these hooks.
;; some c-mode dervied modes wrongfully trigger these hooks (like php-mode)
(add-hook! (c-mode c++-mode ojbc-mode)
(when (memq major-mode '(c-mode c++-mode objc-mode))
(flycheck-mode +1)

View File

@@ -15,8 +15,9 @@
(defun php-extras-company-setup ()) ;; company will set up itself
(map! :map php-mode-map
(:localleader
:nv ";" 'narf/append-semicolon))
(:localleader :nv ";" 'narf/append-semicolon)
:n "gd" 'ac-php-find-symbol-at-point
:n "gD" 'ac-php-location-stack-back)
;; Generate php-extras documentation and completion asynchronously
(unless (file-exists-p (concat php-extras-eldoc-functions-file ".el"))
@@ -38,8 +39,7 @@
(sp-local-pair "<?php" "?>" :when '(("RET")) :post-handlers '("||\n[i]")))
(use-package php-refactor-mode
:init
(add-hook! php-mode '(turn-on-eldoc-mode emr-initialize php-refactor-mode))
:init (add-hook! php-mode '(turn-on-eldoc-mode emr-initialize php-refactor-mode))
:config
(require 'emr)
(mapc (lambda (x)
@@ -60,10 +60,8 @@
;; PHP Repl
(use-package php-boris :defer t
:init
(define-repl! php-mode php-boris)
:config
(evil-set-initial-state 'php-boris-mode 'emacs))
:init (define-repl! php-mode php-boris)
:config (evil-set-initial-state 'php-boris-mode 'emacs))
(define-minor-mode php-laravel-mode
""

View File

@@ -32,7 +32,7 @@
anaconda-mode-eldoc-as-single-line t)
:config
(map! :map anaconda-mode-map :m "gd" 'anaconda-mode-goto-definitions)
(map! :map anaconda-mode-map :m "gd" 'anaconda-mode-find-definitions)
(map! :map anaconda-nav-mode-map :n [escape] 'anaconda-nav-quit)
(advice-add 'anaconda-mode-doc-buffer :after 'narf*anaconda-mode-doc-buffer)