-
Notifications
You must be signed in to change notification settings - Fork 65
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I have created a Syntax highlight file addition for vim #82
Comments
" Vim syntax file
" Language: sh shdoc additions
" Maintainer: Rafael Martinez <[email protected]>
"
" This addition will let you highlight the shdoc anotations
" https://github.com/reconquest/shdoc
"
" Place it in ${HOME}/.vim/after/syntax/
"
" shdoc additions ----------------------------------------
" --------------------------------------------------------
syn match shComment "^\s*\zs#.*$" contains=@shCommentGroup,@shDocTags
syn cluster shDocTags contains=shDocNameTag,shDocFileTag,shDocBriefTag,shDocDescriptionTag,shDocSectionTag,shDocExampleTag,shDocOptionTag,shDocArgTag,shDocNoArgsTag,shDocSetTag,shDocExitcodeTag,shDocStdinTag,shDocStdoutTag,shDocStderrTag,shDocSeeTag,shDocInernalTag
syn match shDocParam contained "\s\zs\S\+"
syn match shDocMultipleString contained "\zs\(\s\S\+\)\+"
syn match shDocDoubleOption contained "\s\zs-\{1,2}\S\+\s\=\(<\S\+>\)\=\(\s\=|\s-\{1,2}\S\+\s\=\(<\S\+>\)\=\)*"
syn match shDocOptionTag contained "\s\zs@option\s\+\S\+" contains=shDocDoubleOption
syn match shDocArgTag contained "\s\zs@arg\s\+\S\+" contains=shDocParam
syn match shDocSetTag contained "\s\zs@set\s\+\S\+" contains=shDocParam
syn match shDocExitcodeTag contained "\s\zs@exitcode\s\+\S\+" contains=shDocParam
syn match shDocSectionTag contained "\s\zs@section\s\+\S\+" contains=shDocMultipleString
syn match shDocNameTag contained "\s\zs@name\>"
syn match shDocFileTag contained "\s\zs@file\>"
syn match shDocBriefTag contained "\s\zs@brief\>"
syn match shDocDescriptionTag contained "\s\zs@description\>"
syn match shDocExampleTag contained "\s\zs@example\>"
syn match shDocNoArgsTag contained "\s\zs@noargs\>"
syn match shDocStdinTag contained "\s\zs@stdin\>"
syn match shDocStdoutTag contained "\s\zs@stdout\>"
syn match shDocStderrTag contained "\s\zs@stderr\>"
syn match shDocSeeTag contained "\s\zs@see\>"
syn match shDocInernalTag contained "\s\zs@internal\>"
hi def link shDocParam Function
hi def link shDocMultipleString Function
hi def link shDocDoubleOption Function
hi def link shDocNameTag Special
hi def link shDocFileTag Special
hi def link shDocBriefTag Special
hi def link shDocDescriptionTag Special
hi def link shDocSectionTag Special
hi def link shDocExampleTag Special
hi def link shDocOptionTag Special
hi def link shDocArgTag Special
hi def link shDocNoArgsTag Special
hi def link shDocSetTag Special
hi def link shDocExitcodeTag Special
hi def link shDocStdinTag Special
hi def link shDocStdoutTag Special
hi def link shDocStderrTag Special
hi def link shDocSeeTag Special
hi def link shDocInernalTag Special
" eof eof eof --------------------------------------------
" shdoc additions ---------------------------------------- |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I have created a syntax highlight file for vim , in order to help visualize this syntax when using it on vim.
Would you like me to do a PR with it? , where would you place it in the directory structure of the project if so?
The text was updated successfully, but these errors were encountered: