NGINX配置文件高亮显示
2012-12-24 12:51
369 查看
Create a folder for your VIM syntax files.
Download the syntax highlighting plugin.
Add it to VIM’s file type definitions. Make sure to adjust the path to your Nginx installation if you need to.
Now enable syntax highlighting in your .vimrc file.
That’s it. Now you’ll have nice colors when you edit your Nginx configs with VIM!
>mkdir -p ~/.vim/syntax/
Download the syntax highlighting plugin.
>curl http://www.vim.org/scripts/download_script.php?src_id=14376 -o ~/.vim/syntax/nginx.vim
Add it to VIM’s file type definitions. Make sure to adjust the path to your Nginx installation if you need to.
>echo "au BufRead,BufNewFile /etc/nginx/conf/* set ft=nginx" >> ~/.vim/filetype.vim
Now enable syntax highlighting in your .vimrc file.
>echo "syntax enable" >> ~/.vimrc
That’s it. Now you’ll have nice colors when you edit your Nginx configs with VIM!
>vim /etc/nginx/conf/nginx.conf
![](http://zduck.com/assets/forposts/nginx-vim-colors.png)
相关文章推荐
- vim高亮显示nginx配置文件的语法结构
- Nginx配置文件高亮显示
- Vim编辑nginx配置文件时高亮显示
- UltraEdit 配置.sh文件高亮显示
- nginx配置让任何文件在浏览器中显示文本text/plain
- Nginx(三):nginx.conf配置文件说明 【2】 文件结构和配置高亮
- nginx配置文件语法高亮显示方法
- vim 配置文件,高亮+自动缩进+行号显示
- 修改home目录下的.vimrc文件,vim配置php高亮显示
- Nginx配置文件语法高亮显示
- nginx配置让任何文件在浏览器中显示文本text/plain
- vim中支持nginx配置文件高亮
- 配置nginx显示目录文件列表
- vim 配置文件 ,高亮+自动缩进+行号+折叠+优化
- Nginx配置文件nginx.conf中文详解
- Nginx简介及配置文件详解
- Nginx配置文件详细说明
- apache nginx 配置文件权限问题 403错误
- (总结)Nginx配置文件nginx.conf中文详解
- Nginx配置文件(nginx.conf)配置详解