Emacs: Create mode for Salt to use with helm-dash
Alan Pearce alan@alanpearce.co.uk
Fri, 08 Aug 2014 11:38:27 +0100
1 files changed, 5 insertions(+), 1 deletions(-)
jump to
M tag-emacs/emacs.d/init.el → tag-emacs/emacs.d/init.el
@@ -336,7 +336,8 @@ (when (require 'helm-dash nil :noerror) (setq-local helm-dash-docsets (if (listp docsets) docsets (list docsets)))))) (add-hook 'ansible-mode-hook (ap/create-helm-dash-hook "Ansible")) (add-hook 'php-mode-hook (ap/create-helm-dash-hook '("PHP" "Symfony"))) - (add-hook 'twig-mode-hook (ap/create-helm-dash-hook '("Twig"))))) + (add-hook 'twig-mode-hook (ap/create-helm-dash-hook '("Twig"))) + (add-hook 'saltstack-mode-hook (ap/create-helm-dash-hook '("SaltStack"))))) (req-package which-func :init (which-function-mode) @@ -693,6 +694,9 @@ ("\\.sls\\'" . yaml-mode))) (define-derived-mode ansible-mode yaml-mode "Ansible") (add-to-list 'auto-mode-alist '("\\(?:ansible.+\\|roles/.+/\\(?:tasks\\|handlers\\)\\)/.+\\.yml\\'" . ansible-mode)) + +(define-derived-mode saltstack-mode yaml-mode "Salt") +(add-to-list 'auto-mode-alist '("\\.sls\\'" . saltstack-mode)) ;;;; Planning