sponsor Vim development Vim logo Vim Book Ad

bnf.vim : Highlight BNFs

 script karma  Rating 33/17, Downloaded by 2635  Comments, bugs, improvements  Vim wiki

created by
Michael Brailsford
 
script type
syntax
 
description
Pretty straight forward.  It highlights a BNF grammar definition.  Not too fancy, but it makes writing a BNF more pleasant.  You can see a screenshot of bnf.vim at http://students.cs.byu.edu/~mtb6/bnf_vim.png .  For more complex BNF grammar definitions, you may want to check out http://vim.sourceforge.net/script.php?script_id=545 which is an EBNF syntax file by Hans Fugal.
 
install details
Just put it in your ~/.vim/syntax directory and add an autocommand to load it up on all files ending with .bnf.  Something like "au bufreadpre,bufnewfile *.bnf set ft=bnf" will do nicely.
 

rate this script Life Changing Helpful Unfulfilling 
script versions (upload new version)

Click on the package to download.

package script version date Vim version user release notes
bnf.vim 1.2 2002-03-25 6.0 Michael Brailsford I forgot to add the proper syntax file starting stuff.  This adds it.
bnf.vim 1.1 2002-03-22 6.0 Michael Brailsford fixed a bug that did not quote string properly if they had the comment char '#' in the quoted string.
bnf.vim 1.0 2002-03-22 6.0 Michael Brailsford Initial upload
ip used for rating: 34.204.194.190

If you have questions or remarks about this site, visit the vimonline development pages. Please use this site responsibly.
Questions about Vim should go to the maillist. Help Bram help Uganda.
   
OSDN.net Logo