使用SecureCRT对Linux vim进行颜色设置
2013-04-23 07:18
441 查看
使用SecureCRT连接服务器时,常常会使用vi或vim打开一些文件。但是打开的文件看起来比较吃力,因为颜色没有像在linux使用vim的那样设置好。在网上搜了一下,有很多《使用SecureCRT对Linux vim进行颜色设置》这样的文章,但其中提供的编辑方式不仅含有行码,而且符号还是全角的,甚至如果在windows下编辑的话还会出现"^M"这样的回车问题。
花了点时间处理,终于可以使用了,分享一下。
Linux的控制台颜色很好设置:Options ->Session Options -> Terminal -> Emulation 中Terminal选择ANSI or linux or xterm,必须钩上 ANSI Colour
vi的颜色设置,编辑~/.vimrc文件,如下:(^[的输入方式是Ctrl+v然后Ctrl+[)
view
plaincopy
to clipboardprint?
" ==============================================
" General settings
" ==============================================
set nocp
set ru
set nu
"set cin
"set cino = :0g0t0(sus
set sm
set ai
set sw=4
set ts=4
set noet
set lbr
set hls
"set backspace = indent , eol , start
"set whichwrap = b , s , < , > , [ , ]
"set fo+ = mB
set selectmode =
"set mousemodel = popup
set keymodel =
"set selection = inclusive
"set matchpairs+ =
" ==============================================
" Cursor movement
" ==============================================
"nnoremap gj
"nnoremap gk
"vnoremap gj
"vnoremap gk
"inoremap gj
"inoremap gk
"nnoremap g$
"nnoremap g0
"vnoremap g$
"vnoremap g0
"inoremap g$
"inoremap g0
"nmap :confirm bd
"vmap :confirm bd
"omap :confirm bd
"map! :confirm bd
syntax on
set foldmethod=syntax
if (has( " gui_running " ))
set nowrap
set guioptions+=b
colo inkpot
else
set wrap
colo ron
endif
"let mapleader = " , "
if !has("gui_running")
set t_Co=8
set t_Sf=^[[3%p1%dm
set t_Sb=^[[4%p1%dm
endif
若提示"^M"有的问题,请使用
dos2unix 命令解决
花了点时间处理,终于可以使用了,分享一下。
Linux的控制台颜色很好设置:Options ->Session Options -> Terminal -> Emulation 中Terminal选择ANSI or linux or xterm,必须钩上 ANSI Colour
vi的颜色设置,编辑~/.vimrc文件,如下:(^[的输入方式是Ctrl+v然后Ctrl+[)
view
plaincopy
to clipboardprint?
" ==============================================
" General settings
" ==============================================
set nocp
set ru
set nu
"set cin
"set cino = :0g0t0(sus
set sm
set ai
set sw=4
set ts=4
set noet
set lbr
set hls
"set backspace = indent , eol , start
"set whichwrap = b , s , < , > , [ , ]
"set fo+ = mB
set selectmode =
"set mousemodel = popup
set keymodel =
"set selection = inclusive
"set matchpairs+ =
" ==============================================
" Cursor movement
" ==============================================
"nnoremap gj
"nnoremap gk
"vnoremap gj
"vnoremap gk
"inoremap gj
"inoremap gk
"nnoremap g$
"nnoremap g0
"vnoremap g$
"vnoremap g0
"inoremap g$
"inoremap g0
"nmap :confirm bd
"vmap :confirm bd
"omap :confirm bd
"map! :confirm bd
syntax on
set foldmethod=syntax
if (has( " gui_running " ))
set nowrap
set guioptions+=b
colo inkpot
else
set wrap
colo ron
endif
"let mapleader = " , "
if !has("gui_running")
set t_Co=8
set t_Sf=^[[3%p1%dm
set t_Sb=^[[4%p1%dm
endif
若提示"^M"有的问题,请使用
dos2unix 命令解决
相关文章推荐
- 使用SecureCRT对Linux vim进行颜色设置
- 使用SecureCRT对Linux vim进行颜色设置
- 使用SecureCRT对Linux vim进行颜色设置【可用的.vimrc文件内容】
- 【转】使用SecureCRT对Linux vim进行颜色设置【可用的.vimrc文件内容】
- 使用SecureCRT对Linux vim进行颜色设置【可用的.vimrc文件内容】
- 使用SecureCRT对Linux vim进行颜色设置
- securecrt中vim行号下划线问题及SecureCRT里root没有高亮的设置,修改linux终端命令行颜色
- SecureCRT连接linux设置vim显示颜色
- 设置secureCRT中vim的字体颜色 分类: B3_LINUX 2014-07-12 22:01 1573人阅读 评论(0) 收藏
- 使用SecureCRT时设置vim显示颜色
- SecureCRT设置linux终端显示颜色
- 如何在Linux上使用VIM进行.Net Core开发
- 一、工具的使用 1、学会使用vim/emacs,vim/emacs是linux下最常用的源码编辑具,不光要学会用它们编辑源码,还要学会用它们进行查找、定位、替换等。新手的话推荐使用vim,这也是我目
- SecureCRT连接linux,vim颜色显示问题
- SecureCRT设置linux终端显示颜色
- Linux下使用Vim进行C/C++ 编程基础知识详解
- [Linux]使用 ifupdown 的逻辑接口定义进行高级网络设置
- linux中使用vim进行开发时.vimrc在哪里
- securecrt和vim中的颜色设置
- flex 使用AdvancedDataGrid进行表头列合并,设置每列背景颜色(1)