Fix ansible layer for upstream changes in ansible minor mode

Ansible minor mode was recently updated to follow emacs-lisp style naming
convention. This commit makes corresponding function name changes in spacemacs
to fix ansible layer.

Reference:
* https://github.com/k1LoW/emacs-ansible/issues/28
* https://github.com/k1LoW/emacs-ansible/pull/31
This commit is contained in:
Ayush Goyal 2019-07-09 01:04:34 +05:30 committed by duianto
parent 6c12121cec
commit 5df46b200e
4 changed files with 8 additions and 7 deletions

View File

@ -1045,6 +1045,7 @@ Other:
(thanks to Codruț Constantin Gușoi)
- Fixed =error void function ansible: auto-decrypt-encrypt=
(thanks to Sylvain Benner)
- Matched upstream Emacs coding convention names (thanks to Ayush Goyal)
**** Asm
- Improvements:
- Added support for =company= package declaration (thanks to Kalle Lindqvist)

View File

@ -35,7 +35,7 @@ password to use somewhere in your =dotspacemacs/user-config= function.
For instance:
#+BEGIN_SRC emacs-lisp
(setq ansible::vault-password-file "path/to/pwd/file")
(setq ansible-vault-password-file "path/to/pwd/file")
#+END_SRC
The default value is the ansible-vault default value: =~/.vault_pass.txt=.
@ -49,7 +49,7 @@ password file for a given environment. Example:
;;; Directory Local Variables
;;; For more information see (info "(emacs) Directory Variables")
((yaml-mode . ((ansible::vault-password-file . "path/to/vault_file"))))
((yaml-mode . ((ansible-vault-password-file . "path/to/vault_file"))))
#+END_SRC
*** Automatic encryption and decryption

View File

@ -22,7 +22,7 @@
(defun spacemacs/ansible-auto-decrypt-encrypt-vault ()
"Auto decrypt/encrypt Vault files."
(when (spacemacs//ansible-should-enable?)
(ansible::auto-decrypt-encrypt)))
(ansible-auto-decrypt-encrypt)))
(defun spacemacs/ansible-company-maybe-enable ()
"Add the ansible company backend only for when ansible mode is active."

View File

@ -19,11 +19,11 @@
(defun ansible/init-ansible ()
(use-package ansible
:defer t
:commands ansible::auto-decrypt-encrypt
:commands ansible-auto-decrypt-encrypt
:init
(progn
(add-hook 'yaml-mode-hook 'spacemacs/ansible-maybe-enable)
(put 'ansible::vault-password-file 'safe-local-variable #'stringp)
(put 'ansible-vault-password-file 'safe-local-variable #'stringp)
(if ansible-auto-encrypt-decrypt
;; add this hook to local-vars-hook to allow users to specify
;; a password file in directory local variables
@ -35,8 +35,8 @@
:config
(progn
(spacemacs/set-leader-keys-for-minor-mode 'ansible
"bd" 'ansible::decrypt-buffer
"be" 'ansible::encrypt-buffer))))
"bd" 'ansible-decrypt-buffer
"be" 'ansible-encrypt-buffer))))
(defun ansible/init-ansible-doc ()
(use-package ansible-doc