vim 添加 as 和 mxml 的语法高亮

vim 很强大,学习中;配置下 as 和 mxml 的语法高亮,直接写 flash

下载一下三个文件:

  1. http://abdulqabiz.com/files/vim/actionscript.vim
  2. http://abdulqabiz.com/files/vim/mxml.vim
  3. http://vim.cybermirror.org/patches/dtd.vim (这个是 xml 的语法,如果不装这个,mxml 会报错)
下载好后,把3个文件拷贝到~/.vim/syntax/下,如果没有可以创建。

为了偷懒,修改了下启动程序./.vimrc 如下:

autocmd BufRead *.as set filetype=actionscript
autocmd BufRead *.mxml set filetype=mxml
这个是在ubuntu下的配置,如过是windows下的vim要参考下也可以配置好的。