| 网站首页 | 新闻中心 | 系统安全 | 网络安全 | 安全技术 | 下载中心 | 安全365社区 |
安全365
收藏本站
设为首页
会员登录:
站内搜索: 新闻中心 系统安全 网络安全 安全技术 下载中心
| 系统安全首页 | 漏洞分析 | 入侵检测 | 升级补丁 | 安全配置 |
Linux下VI编辑器不能保存中文的问题解决
Linux下VI编辑器不能保存中文的问题解决
作者:sixth 文章来源:赛迪网 点击数: 更新时间:2007-11-14 1:10:36
 

Linux下VI编辑器如果出现不能保存中文的问题

你可以在当前用户下,建.vimrc文件内容如下:

set nocompatible " Use Vim defaults (much better!) 
set bs=indent,eol,start " Allow backspacing over everything in insert mode 
set ai " Always set auto-indenting on 
"set backup " Keep a backup file 
set viminfo='20,\"500 " read/write a .viminfo file -- limit regs to 500 lines 
set history=100 " keep 50 lines of command history 
set ruler " Show the cursor position all the time 

colorscheme elflord " Make the colors brighter for transparent terminals 
set ts=4 " Set TAB Stop 
set shiftwidth=4 " Set shift width in programming 
set textwidth=0 " Don't wrap words by default 
set ignorecase " Ignore case in searching 
set smartcase " Search case-sensitively when capitalized letter found in pattern 
set nobackup " Don't keep a backup file 
set showcmd " Show (partial) command in status line 
set showmatch " Show matching brackets 
set incsearch " Incremental Search 
"set autowrite " Automatically save file before :next and : prev 
"set nowrap " Do not wrap text 
"set textwidth=80 " Place automatic text breaks 

???? Enable Chinese encoding support 
set encoding=euc-cn 
if v:lang =~ "^zh_CN" 
set fileencodings=gb2312 
set guifontset=*-r-* " You may change the font to your like 
endif 

" Switch syntax highlighting on, when the terminal has colors 
" Also switch on highlighting the last used search pattern. 
if &t_Co > 2 || has("gui_running") 
syntax on 
set hlsearch 
endif 

"set nohlsearch "If you do not like highlighting search pattern
文章录入:郝丽    责任编辑:郝丽 
  • 上一篇文章:

  • 下一篇文章:
  • 【字体: 】【发表评论】【加入收藏】【告诉好友】【打印此文】【关闭窗口
      网友评论:(只显示最新10条。评论内容只代表网友观点,与本站立场无关!)
     
     
     
    桌面Linux实战“宝典” 
    忘记Linux操作系统密码后
    Linux系统桌面瘦身加速工
    恢复误删除的Linux文件全
    SCO UNIX到Linux操作系统
    Linux操作系统下修改IP、
    在VMware中Linux操作系统
    Linux下安装一系列与Jav
    在Linux中 如何将LCD的刷
    Linux 系统用户账号管理
    站长邮箱:webmaster@anquan365.com
    联系电话:86-10-67634029 点击这里给我发消息

    Copyright © 2006-2008 www.anquan365.com 北京华安普特网络科技有限公司 版权所有