]> git.pld-linux.org Git - packages/vim.git/commitdiff
- better specURL
authorElan Ruusamäe <glen@pld-linux.org>
Sun, 1 May 2005 18:50:05 +0000 (18:50 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
- syntax hiliting in %changelog area

Changed files:
    spec.vim -> 1.17

spec.vim

index 0eb3c4c401aff7c08ac10c83daf319536f0b0f2c..c0bfa703862c12af4a0274ad10b3245b690b1949 100644 (file)
--- a/spec.vim
+++ b/spec.vim
@@ -48,7 +48,7 @@ syn keyword specMonth   contained January February March April May June July Aug
 "#, @, www
 syn match specNumber '\(^-\=\|[ \t]-\=\|-\)[0-9.-]*[0-9]'
 syn match specEmail contained "<\=\<[A-Za-z0-9_.-]\+@\([A-Za-z0-9_-]\+\.\)\+[A-Za-z]\+\>>\="
-syn match specURL      contained '\<\(\(https\{0,1}\|ftp\)://\|\(www[23]\{0,1}\.\|ftp\.\)\)[A-Za-z0-9._/~:,#-]\+\>'
+syn match specURL      contained '\<\(\(https\{0,1}\|ftp\)://\|\(www[23]\{0,1}\.\|ftp\.\)\)[A-Za-z0-9._/~:,#?=-]\+\>'
 syn match specURLMacro contained '\<\(\(https\{0,1}\|ftp\)://\|\(www[23]\{0,1}\.\|ftp\.\)\)[A-Za-z0-9._/~:,#%{}-]\+\>' contains=specMacroIdentifier
 
 "TODO take specSpecialVariables out of the cluster for the sh* contains (ALLBUT)
@@ -129,9 +129,13 @@ syn region specScriptArea matchgroup=specSection
        \ contains=specSpecialVariables,specVariables,@specCommands,specVariables,shDo,shFor,shCaseEsac,specNoNumberHilite,specCommandOpts,shComment,shIf,specSpecialChar,specMacroIdentifier,specSectionMacroArea,specSectionMacroBracketArea,shOperator,shQuote1,shQuote2,specSectionMacroBcondArea
 
 "%% Changelog Section %%
-syn region specChangelogArea matchgroup=specSection start='^%changelog' end='^%'me=e-1 contains=specEmail,specURL,specWeekday,specMonth,specNumber,specComment,specLicense
-
+syn region specChangelogArea matchgroup=specSection start='^%changelog' end='^%'me=e-1 
+       \ contains=specEmail,specURL,specWeekday,specMonth,specNumber,specComment,specLicense,specRevision,specLogMessage,specLogTag,specLogError
 
+syn match specRevision contained "^Revision [.0-9]\+  [/0-9]\+ [:0-9]\+  [a-zA-Z0-9]\+$"
+syn region specLogMessage contained start="^[- ] " end="$" contains=specLogError,specURL,specEmail
+syn region specLogTag contained start="^\$Log" end="\$$"
+syn match specLogError contained "%%"
 
 "------------------------------------------------------------------------------
 "here's the shell syntax for all the Script Sections
@@ -242,6 +246,11 @@ if version >= 508 || !exists("did_spec_syntax_inits")
   HiLink specListedFilesPrefix         Statement
   HiLink specListedFilesShare          Statement
 
+  HiLink specRevision                  Number
+  HiLink specLogMessage                        Identifier
+  HiLink specLogTag                    NONE
+  HiLink specLogError                  Error
+
   delcommand HiLink
 endif
 
This page took 0.061877 seconds and 4 git commands to generate.