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

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

[nongnu] elpa/nginx-mode a3ea629 33/34: Merge pull request #17 from joew


From: ELPA Syncer
Subject: [nongnu] elpa/nginx-mode a3ea629 33/34: Merge pull request #17 from joewreschnig/magic-fallback-mode
Date: Sun, 29 Aug 2021 11:24:18 -0400 (EDT)

branch: elpa/nginx-mode
commit a3ea62939516a24abd1e4efb6194bbcc5981502f
Merge: 9e25e1f 95cb916
Author: Andrew J. Cosgriff <andrew@cosgriff.name>
Commit: GitHub <noreply@github.com>

    Merge pull request #17 from joewreschnig/magic-fallback-mode
    
    Add top-level Nginx configuration blocks to magic-fallback-mode-alist.
---
 nginx-mode.el | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/nginx-mode.el b/nginx-mode.el
index 03ec64f..34f1e11 100644
--- a/nginx-mode.el
+++ b/nginx-mode.el
@@ -190,6 +190,11 @@ The variable nginx-indent-level controls the amount of 
indentation.
 (add-to-list 'auto-mode-alist '("nginx\\.conf\\'"  . nginx-mode))
 ;;;###autoload
 (add-to-list 'auto-mode-alist '("/nginx/.+\\.conf\\'" . nginx-mode))
+;;;###autoload
+(add-to-list
+ 'magic-fallback-mode-alist
+ '("\\(?:.*\n\\)*\\(?:http\\|server\\|location .+\\|upstream .+\\)[ \n\t]+{"
+   . nginx-mode))
 
 (provide 'nginx-mode)
 



reply via email to

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