Coder Social home page Coder Social logo

ivim's Introduction

目前不建议使用ivimInstall.sh进行安装

这是我自己的vim配置文件,基于spf-13-vim. 主要是添加了一些我自己觉得很有用的plugin,然后修改了一下快捷键,最主要的目的是为了我自己使用,如果对你也有些用处那真是再好不过了。

安装(Mac OSX)

下面讲的是Mac系统下的安装,没试过在windows系统下的安装。

安装所需要的Dependencies

  1. 安装MacVim。我安装的是Installer版本
  2. 安装ruby和python。Mac系统是自带ruby和python的,如果你的系统没有,那么就安装一下吧
  3. 安装NodeJS。有几个插件需要用到NodeJS的npm命令
  4. 安装HomeBrew。我觉得这是Mac系统下非常好用的工具,用来安装Mac系统缺失的包,类似于Linux系统下得apt-get
  5. 安装js-beautify。使用js-beautify来format JavaScript, HTML和CSS。你可以用这个命令进行安装npm -g install js-beautify,如果出现错误,那很可能就是权限的问题,可以加上sudo
  6. 安装ctags,ctags可以生成一个函数定义列表,方便你在代码中查找函数。你可以用这个命令安装brew install ctags。安装完成后,你可以用which ctags查找安装路径
  7. 安装CMake, CMake是一个跨平台,开源的build系统。你可以使用如下命令安装brew install cmake
  8. 安装Mercurial,你可以去这个网站下载安装包http://mercurial.berkwood.com
  9. 安装最新版本的vim,由于YouCompleteMe需要最新版本的vim。

安装

  1. 下载或者checkout ivim。用如下命令就行,git clone https://github.com/shaoke/ivim.git。假如你把ivim文件夹放在如下路径 - /Users/UX/MyGithub/ivim,里面应该有.vimrc.bundles.local,.vimrc.local等文件

  2. 在你当前用户的根目录(假如是/Users/UX)下创建如下文件链接。

    • .vimrc.bundles.local。在这里可以添加plugins。可用如下命令创建ln -s /Users/UX/MyGithub/ivim/.vimrc.bundles.local ~/.vimrc.bundles.local
    • .vimrc.before.local。可以设置一些变量覆盖spf13-vim中得设置。 ln -s /Users/UX/MyGithub/ivim/.vimrc.before.local ~/.vimrc.before.local
    • .vimrc.local。可用如下命令ln -s /Users/UX/MyGithub/ivim/.vimrc.local ~/.vimrc.local
  3. 安装spf-13-vim。你可以用这么命令进行安和更新curl https://j.mp/spf13-vim3 -L -o - | sh

经过以上步骤就安装完成了,你可以打开的MacVim或者直接用vim来试用了。

常用快捷键

  • <Leader>: ,
  • Ctrl+e, <Leader>e:显示file explorer - NERDTree
  • Shift+H, Shift+L:切换tab
  • <Leader>cc: 注释当前行或者在visual mode下选中的text
  • <Leader>cm: 块注释选中的行
  • <Leader>cu: 取消选中行的注释
  • 怎么样选中多行:
  1. Shift+v进入Visual Mode

  2. 从当前行选起

    • <n>gg: 到第n行。比如:当前行到第10行,那就是10G
    • <n>j: 往下n行
    • <n>k: 往上n行
    • <n>w: 往右n行

ivim's People

Contributors

neoskx avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Forkers

ifrog

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.