From b12c7138893d7d75337549930a0bdd0ffc13b104 Mon Sep 17 00:00:00 2001 From: Tom Willemse Date: Mon, 9 Jul 2018 19:52:22 -0700 Subject: Add extra PHP alignment rule --- emacs/.emacs.d/init/oni-align.el | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/emacs/.emacs.d/init/oni-align.el b/emacs/.emacs.d/init/oni-align.el index 9e42e3f..3e45844 100644 --- a/emacs/.emacs.d/init/oni-align.el +++ b/emacs/.emacs.d/init/oni-align.el @@ -85,7 +85,23 @@ (add-to-list 'align-rules-list `(php-array-arrow - (regexp . ,(rx any (group whitespace) "=>" any)) + (regexp . ,(rx any (group (zero-or-more whitespace)) "=>" any)) + (group . (1)) + (modes . '(php-mode web-mode)) + (repeat . t))) + +;; The WordPress coding standards specify that multiple assignments +;; should have their assignment operators aligned. + +;;