首页 > 其他分享 >vimrc

vimrc

时间:2023-06-04 12:33:41浏览次数:74  
标签:set vimrc shift ----------------------------------------------------------------

vsvimrc

set enc=utf-8
set fencs=utf-8,gbk,big5,cp936,gb18030,gb2312,utf-16
set fenc=utf-8
set shortmess=atI

"禁止bell
set belloff=all
set visualbell
set t_vb=

let mapleader = "\<Space>"
inoremap jj <ESC>

"-------------------------------------------------------------------------------
" 注释 vim-commentary
"-------------------------------------------------------------------------------
" toggle注释单行
" normal mode: gcc

" toggle 多行注释
" 首先进入visual mode,然后选择。gc toggle注释

"-------------------------------------------------------------------------------
" 缩进
"-------------------------------------------------------------------------------
"  visual mode
"  shift+< 然后 > 增加缩进
"  shift+> 然后 > 减少缩进

" normal mode
" shift + > + >
" shift + < + <

"-------------------------------------------------------------------------------
" 大小写转换
"-------------------------------------------------------------------------------
"  visual mode
"  ~

"-------------------------------------------------------------------------------
"  视图
"-------------------------------------------------------------------------------
" normal mode
" <C-O>  <C-I> zz
" <C-E>  <C-D>
" <C-Y>  <C-U>
" G      gg

"-------------------------------------------------------------------------------
"  选择
"-------------------------------------------------------------------------------
" Make vaa select the entire file...
xmap aa VGo1G

set nocompatible

set showcmd

set mouse=a

" 启用256色
set t_Co=256

" 关闭自动折行
set nowrap

"Square up visual selections...
set virtualedit=block

" Make BS/DEL work as expected in visual modes (i.e. delete the selected text)...
xmap <BS> x

"可随时用倒退键删除
set backspace=2


"行折叠
map <leader>z  :set invwrap <CR>

"窗口分隔
map <leader>=  :vsp <CR>
map <leader>-  :sp <CR>

"窗口跳转
"<C-W> jkhl


"-------------------------------------------------------------------------------
" 搜索
"-------------------------------------------------------------------------------
" 搜索时,高亮显示匹配结果。
set hlsearch
"highlight clear Search

"清除高亮
map <leader>z :nohl <CR>

" 搜索设置
set ignorecase
set incsearch

set clipboard=unnamed

nnoremap gd :vsc VAssistX.GotoImplementation<CR>

" auto save without plugin
autocmd TextChanged,TextChangedI * silent write

.ideavimrc

set enc=utf-8
set fencs=utf-8,gbk,big5,cp936,gb18030,gb2312,utf-16
set fenc=utf-8
set shortmess=atI

"禁止bell
set belloff=all
set visualbell
set t_vb=

let mapleader = "\<Space>"
inoremap jj <ESC>

"-------------------------------------------------------------------------------
" 注释 vim-commentary
"-------------------------------------------------------------------------------
" toggle注释单行
" normal mode: gcc

" toggle 多行注释
" 首先进入visual mode,然后选择。gc toggle注释

"-------------------------------------------------------------------------------
" 缩进
"-------------------------------------------------------------------------------
"  visual mode
"  shift+< 然后 > 增加缩进
"  shift+> 然后 > 减少缩进

" normal mode
" shift + > + >
" shift + < + <

"-------------------------------------------------------------------------------
" 大小写转换
"-------------------------------------------------------------------------------
"  visual mode
"  ~

"-------------------------------------------------------------------------------
"  视图
"-------------------------------------------------------------------------------
" normal mode
" <C-O>  <C-I> zz
" <C-E>  <C-D>
" <C-Y>  <C-U>
" G      gg

"-------------------------------------------------------------------------------
"  选择
"-------------------------------------------------------------------------------
" Make vaa select the entire file...
xmap aa VGo1G

set nocompatible

set showcmd

set mouse=a

" 启用256色
set t_Co=256

" 关闭自动折行
set nowrap

"Square up visual selections...
set virtualedit=block

" Make BS/DEL work as expected in visual modes (i.e. delete the selected text)...
xmap <BS> x

"可随时用倒退键删除
set backspace=2


"行折叠
map <leader>w  :set invwrap <CR>

"窗口分隔
map <leader>=  :vsp <CR>
map <leader>-  :sp <CR>

"窗口跳转
"<C-W> jkhl


"-------------------------------------------------------------------------------
" 搜索
"-------------------------------------------------------------------------------
" 搜索时,高亮显示匹配结果。
set hlsearch
"highlight clear Search

"清除高亮
map <leader>z :nohl <CR>

" 搜索设置
set ignorecase
set incsearch

set clipboard=unnamed

" auto save without plugin
autocmd TextChanged,TextChangedI * silent write

标签:set,vimrc,shift,----------------------------------------------------------------
From: https://www.cnblogs.com/Searchor/p/17455513.html

相关文章

  • 如何配置Vimrc文件
    如何配置Vimrc文件发布时间:2016-11-2203:07:33在炮制你自己的.vimrc配置时,这里只有一个原则.不要把任何你不理解的一行放到你的vimrc中.互联网上有以吨计的入门手册,诸如这篇文章.它们之中包含各种令人惊叹的Hack技巧,这可以记你的Vim更好,但为了让你的环境更好完全......
  • 10、.vimrc
    setignorecasesetautoindentautocmdBufNewFile*.shexec":callSetTitle()"funcSetTitle()ifexpand("%:e")=='sh'callsetline(2,"#[---......
  • 使用.vimrc配置vim
    使用.vimrc配置vim。11"语法高亮22syntaxon3344"主题色55colorschemedelek"想要看vim自带的主题,在非编辑模式下:colorscheme,然后......
  • vimrc
    "Allsystem-widedefaultsaresetin$VIMRUNTIME/debian.vimandsourcedby"thecallto:runtimeyoucanfindbelow.Ifyouwishtochangeanyofthose"sett......
  • Ubutu下 vim 的.vimrc配置以及YourCompletedMe无法stl代码提示的解决办法
    我的vim效果预览主题颜色是desertEx有目录树,和函数显示器,以及代码提示,根据文件类型自动生成文件头下面是我的.vimrc配置!请全屏观看点击查看代码setnocompatible......
  • ideavimrc 示例
    """Mapleadertospace---------------------letmapleader="""""mac设置normal模式,为英文输入letkeep_input_source_in_normal="com.apple.keylayout.ABC""""......
  • vimrc
    vimrc$vi~/.vimrcsetnumber"显示行号"setnowrap"不换行setshiftwidth=2"默认缩进4个空格setsofttabstop=2"使用tab时tab空格数settabstop=2"tab......
  • 无插件vimrc
    "UltimateVIMRCwithoutplugin"Copyrights@Yavobo"Version0.10"Createdin2016.11.0211:11"Updatedin2020.03.1016:19""Describe:"Thisisan......
  • Mac: zsh vimrc
     #>>>condainitialize>>>#!!Contentswithinthisblockaremanagedby'condainit'!!__conda_setup="$('/Users/zliu3/opt/anaconda3/bin/conda''shell.zs......