[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/nginx-mode 95cb916 32/34: Add top-level Nginx configuratio
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/nginx-mode 95cb916 32/34: Add top-level Nginx configuration blocks to magic-fallback-mode-alist. |
Date: |
Sun, 29 Aug 2021 11:24:18 -0400 (EDT) |
branch: elpa/nginx-mode
commit 95cb9169e398b7a62916d6c15bc279f2246861a6
Author: Joe Wreschnig <joe.wreschnig@gmail.com>
Commit: Joe Wreschnig <joe.wreschnig@gmail.com>
Add top-level Nginx configuration blocks to magic-fallback-mode-alist.
As mentioned in issue #6, Nginx configuration today is often edited
indirectly as part of a CMS, and the files are often fragments rather
than a single nginx.conf.
By adding the common top-level blocks to a magic mode alist, we can
still automatically detect these files. By choosing the fallback
alist, we still allow other major modes to make a stronger claim based
on extension or literal content / interpreter match.
---
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)
- [nongnu] elpa/nginx-mode a2bab83 34/34: bump version, (continued)
- [nongnu] elpa/nginx-mode a2bab83 34/34: bump version, ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode 3d193f7 05/34: * nginx-mode.el: fix to use md-readme to generate a handy README.md file, ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode 87ee3d1 07/34: add a version number to make marmalade-repo.org happy, ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode 72e1ea5 09/34: Remove font-lock-pseudo-keyword-face. I can't think of anything else to highlight semicolons with, and really, it doesn't matter that much anyway. Fixes #5., ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode ad2f140 08/34: fix commenting/uncommenting as per suggestion from @mbunkus - fixes #3., ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode 2cbac8a 15/34: Merge pull request #8 from yasuyk/auto-mode-alist, ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode dd61d1d 23/34: font-lock-operator-face is gone.\n\nFixes #14., ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode a04cef3 25/34: Update README.md, ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode f33abe7 26/34: Use syntax table instead of font-lock regexp, ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode c13fa62 27/34: Merge pull request #15 from zonuexe/feature/comment-syntax-table, ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode 95cb916 32/34: Add top-level Nginx configuration blocks to magic-fallback-mode-alist.,
ELPA Syncer <=
- [nongnu] elpa/nginx-mode 304c9e2 24/34: one more ref to font-lock-operator-face., ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode bb5d84b 21/34: removed sites-enabled from default (has issues with apache-mode autoloads), ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode 99d5eea 02/34: mention where you can find it, ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode 0600403 03/34: syntax highlighting improvements, of a sort., ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode 06fe730 10/34: add some auto-mode-alist magic. Fixes #6., ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode 82098c5 19/34: auto-mode-alist now works :-), ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode 8a296e3 22/34: Merge pull request #11 from chillum/master, ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode 47aaf2c 29/34: Remove `run-hook`, it is run automatically., ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode c37ae5f 30/34: Merge pull request #16 from Fuco1/patch-1, ELPA Syncer, 2021/08/29
- [nongnu] elpa/nginx-mode 9fc6ef2 01/34: initial checkin of working code, ELPA Syncer, 2021/08/29