emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] master 42ecef5 381/433: Allow omitting the close tag of the last


From: Dmitry Gutov
Subject: [elpa] master 42ecef5 381/433: Allow omitting the close tag of the last PHP code block.
Date: Thu, 15 Mar 2018 19:44:39 -0400 (EDT)

branch: master
commit 42ecef5863b86b5ed332b049f8b63e5143f87db1
Author: Akinori MUSHA <address@hidden>
Commit: Akinori MUSHA <address@hidden>

    Allow omitting the close tag of the last PHP code block.
    
    It is common manners to omit the close tag to avoid the trailing newline 
problem.
---
 mmm-sample.el | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/mmm-sample.el b/mmm-sample.el
index 6320a31..0f31ae2 100644
--- a/mmm-sample.el
+++ b/mmm-sample.el
@@ -320,7 +320,7 @@ and MODE is a major mode function symbol.")
     :submode php-mode
     :face mmm-output-submode-face
     :front "<\\?php *echo "
-    :back "\\?>"
+    :back "\\(\\?>\\|\\'\\)"
     :include-front t
     :front-offset 5
     :insert ((?e php-echo nil @ "<?php" @ " echo " _ " " @ "?>" @))
@@ -329,7 +329,7 @@ and MODE is a major mode function symbol.")
     :submode php-mode
     :face mmm-code-submode-face
     :front "<\\?\\(php\\)?"
-    :back "\\?>"
+    :back "\\(\\?>\\|\\'\\)"
     :insert ((?p php-section nil @ "<?php" @ " " _ " " @ "?>" @)
              (?b php-block nil @ "<?php" @ "\n" _ "\n" @ "?>" @))
     )))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]