linux中gvim配置

您所在的位置:网站首页 gvim配置文件修改怎么保存 linux中gvim配置

linux中gvim配置

2024-06-01 02:22| 来源: 网络整理| 查看: 265

文章目录 前言一、在哪配置二、设置语句三、运行结果

前言

对于在linux上工作的硬件工程师来说,换到一个新的服务器或者工作环境,首先要做的几件事中肯定有一项是设置gvim配置,这里纪录下我的常用gvim配置和注释。 仅供参考,如有错误,欢迎指正,有其他更好的配置也欢迎补充~

一、在哪配置

bash或者csh环境下,直接在host目录下(cd ~/)添加/修改“.vimrc”文件,然后编辑。

二、设置语句

配置与注释如下,由于不是“.sh”文件,可以把注释行删掉再写入.vimrc中,防止source时也被加载。

#syntax highlighting 设置语法高亮 syntax on #show the line number 显示行号 set number #set gui font 设置字体,可修改为自己喜欢的字体和字号 set guifont=Bitstream\ Vera\ Sans\ Mono\ 12 #set gui theme 设置主题(夜间模式) colorscheme evening #show command prompt set showcmd #enable the mouse 设置可用鼠标选择、操作 set mouse=a set selection=exclusive set selectmode=mouse,key #set cursor 设置光标 set cursorline set cursorcolumn #show the cursor position at gui right bottom 显示光标所在位置 set ruler #search highlighting 搜索高亮显示 set hlsearch #search ignoring case 搜索忽略大小写 set smartcase #highlight the words char by char when search 搜索时每输入一个字符就跳转到搜索到的地方,回车结束 set incsearch #always show the status line 始终显示状态行 set laststatus=2 #show parentheses match 括号匹配 set showmatch #set tab length 设置Tab键长度 set tabstop=4 #set the length of autoindent 设置自动缩进长度 set autoindent set shiftwidth=4 #no wrapping and ad a bottom scroll bar 不自动换行,并且在底部加一个水平滚动条(配合使用!) set nowrap set guioptions+=b #set the initial gui position and size 设置初始打开gui界面的位置和大小 winpos 100 100 set lines=40 set columns=100 三、运行结果

如图,是我比较习惯的gvim界面~ gvim界面



【本文地址】


今日新闻


推荐新闻


CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3