[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master c95f9b0 157/433: Added file (contributed by Marcus Harnisc
From: |
Dmitry Gutov |
Subject: |
[elpa] master c95f9b0 157/433: Added file (contributed by Marcus Harnisch). |
Date: |
Thu, 15 Mar 2018 19:43:54 -0400 (EDT) |
branch: master
commit c95f9b0613abfc21094bb549e0c85529250e9348
Author: mas <mas>
Commit: mas <mas>
Added file (contributed by Marcus Harnisch).
---
mmm-rpm.el | 76 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 76 insertions(+)
diff --git a/mmm-rpm.el b/mmm-rpm.el
new file mode 100644
index 0000000..6d37076
--- /dev/null
+++ b/mmm-rpm.el
@@ -0,0 +1,76 @@
+;;; mmm-rpm.el --- MMM submode class for RPM spec files
+
+;; Copyright (C) 2000 by Marcus Harnisch <address@hidden>
+
+;;{{{ GPL
+
+;; This file is free software; you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 2, or (at your option)
+;; any later version.
+
+;; This file is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with GNU Emacs; see the file COPYING. If not, write to
+;; the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
+
+;;}}}
+
+;;; Commentary:
+
+;; This file contains the definition of an MMM Mode submode class for
+;; editing shell script sections within RPM (Redhat Package Manager)
+;; spec files. I recommend to use it in combination with
+;; rpm-spec-mode.el by Stig Bj�rlykke <address@hidden> and Steve
+;; Sanbeg <address@hidden> (http://www.xemacs.org/~stigb/rpm-spec-mode.el)
+
+;;; Installation:
+
+;; 1. Copy this file where Emacs can find it.
+;;
+;; 2. Add the following lines to one of your startup files (e.g. ~/.emacs):
+;;
+;; (add-to-list 'mmm-mode-ext-classes-alist
+;; '(rpm-spec-mode "\\.spec\\'" rpm-sh))
+
+;;; Code:
+
+(require 'mmm-auto)
+
+(defconst mmm-rpm-sh-start-tags
+ '("prep" "build" "install" "clean" "preun" "postun" "pre"
+ "post" "triggerin" "triggerun" "triggerpostun")
+ "List containing RPM tags that start a shell-script section in a spec file")
+
+(defvar mmm-rpm-sh-end-tags
+ (append '("files" "description" "package") mmm-rpm-sh-start-tags)
+ "List containing RPM tags that end a shell-script section in a spec file")
+
+(defvar mmm-rpm-sh-start-regexp
+ (concat "^%" (mmm-regexp-opt mmm-rpm-sh-start-tags t) "\\b.*$")
+ "Regexp matching RPM tags that start a shell-script section in a spec file")
+
+(defvar mmm-rpm-sh-end-regexp
+ (concat "\\'\\|^%" (mmm-regexp-opt mmm-rpm-sh-end-tags t) "\\b.*$")
+ "Regexp matching RPM tags that end a shell-script section in a spec file")
+
+(mmm-add-classes
+ `((rpm-sh
+ :submode sh-mode
+ ;; match tags that starts sh-script region
+ :front ,mmm-rpm-sh-start-regexp
+ ;; match end of buffer or next tag that ends sh-script region
+ :back ,mmm-rpm-sh-end-regexp
+ :front-offset 1
+ :back-offset 0
+ :save-matches 0
+ )))
+
+(provide 'mmm-rpm)
+
+;;; mmm-rpm.el ends here
\ No newline at end of file
- [elpa] master e0a2e51 196/433: (mmm-save-local-variables): Added syntax and indentation variables for, (continued)
- [elpa] master e0a2e51 196/433: (mmm-save-local-variables): Added syntax and indentation variables for, Dmitry Gutov, 2018/03/15
- [elpa] master d674c74 202/433: (mmm-format-matches): Removed reference to `count' variable., Dmitry Gutov, 2018/03/15
- [elpa] master d64a049 192/433: Modified classes to use preferred mode list., Dmitry Gutov, 2018/03/15
- [elpa] master b0b7520 217/433: # Added comment about bug fix., Dmitry Gutov, 2018/03/15
- [elpa] master 293e13a 198/433: (mmm-format-matches): Changed to allow accessing any subexp, not, Dmitry Gutov, 2018/03/15
- [elpa] master 2a00982 215/433: * mmm-mason.el (mmm-mason-end-line, mmm-mason-start-line): Use bolp, Dmitry Gutov, 2018/03/15
- [elpa] master 1ef198a 219/433: # Updated, Dmitry Gutov, 2018/03/15
- [elpa] master ef73242 214/433: Added `javascript-mode' to list of C-derived modes., Dmitry Gutov, 2018/03/15
- [elpa] master 23170fe 205/433: Added `mmm-primary-mode' variable so that `major-mode' can be saved., Dmitry Gutov, 2018/03/15
- [elpa] master 72ca55f 213/433: # Updated menus., Dmitry Gutov, 2018/03/15
- [elpa] master c95f9b0 157/433: Added file (contributed by Marcus Harnisch).,
Dmitry Gutov <=
- [elpa] master c9c6c19 194/433: Added ePerl and JSP to autoload., Dmitry Gutov, 2018/03/15
- [elpa] master c659e19 141/433: Released 0.4.4, Dmitry Gutov, 2018/03/15
- [elpa] master d06e9a3 143/433: (mmm-here-doc-get-mode): Extended to recognize names like TEXT_EOF., Dmitry Gutov, 2018/03/15
- [elpa] master 28cda1d 160/433: # Added headers., Dmitry Gutov, 2018/03/15
- [elpa] master ad9724f 140/433: # Updated., Dmitry Gutov, 2018/03/15
- [elpa] master 36e10b1 167/433: (mmm-ify): Explicitly set defaults for keywords in &rest parameter., Dmitry Gutov, 2018/03/15
- [elpa] master 944e3b4 173/433: Set MASON_VERSION., Dmitry Gutov, 2018/03/15
- [elpa] master 588edf0 169/433: (mmm-set-file-name-for-modes): Changed to a list for finer control., Dmitry Gutov, 2018/03/15
- [elpa] master 5f96947 177/433: # Added comment about apostrophes, Dmitry Gutov, 2018/03/15
- [elpa] master a58c9bc 178/433: Added comment about adding files to the distribution., Dmitry Gutov, 2018/03/15