Type something to search...
Vim 常用套件與指令

Vim 常用套件與指令

  • Productivity
  • 05 Jul, 2017

視窗

將目前視窗放到最大

Ctrl + w + _

移動到上/下面視窗

Ctrl + w + up/down

套件管理

從 vimrc 自動安裝 Vundle

" http://erikzaadi.com/2012/03/19/auto-installing-vundle-from-your-vimrc/
" Setting up Vundle - the vim plugin bundler
    let iCanHazVundle=1
    let vundle_readme=expand('~/.vim/bundle/vundle/README.md')
    if !filereadable(vundle_readme) 
        echo "Installing Vundle.."
        echo ""
        silent !mkdir -p ~/.vim/bundle
        silent !git clone https://github.com/VundleVim/Vundle.vim ~/.vim/bundle/vundle
        let iCanHazVundle=0
    endif
    set nocompatible              " be iMproved, required
    filetype off                  " required
    set rtp+=~/.vim/bundle/vundle/
    call vundle#begin()
    Plugin 'VundleVim/Vundle.vim'
    "Add your bundles here
    Plugin 'Syntastic' "uber awesome syntax and errors highlighter
    Plugin 'altercation/vim-colors-solarized' "T-H-E colorscheme
    Plugin 'https://github.com/tpope/vim-fugitive' "So awesome, it should be illegal 
    "...All your other bundles...
    if iCanHazVundle == 0
        echo "Installing Vundles, please ignore key map error messages"
        echo ""
        :PluginInstall
    endif

    call vundle#end() 
    "must be last
    filetype plugin indent on " load filetype plugins/indent settings
    colorscheme solarized
    syntax on                      " enable syntax
 
" Setting up Vundle - the vim plugin bundler end

http://erikzaadi.com/2012/03/19/auto-installing-vundle-from-your-vimrc/
” Setting up Vundle - the vim plugin bundler
let iCanHazVundle=1
let vundle_readme=expand(’~/.vim/bundle/vundle/README.md’)
if !filereadable(vundle_readme)
echo “Installing Vundle..”
echo ""
silent !mkdir -p ~/.vim/bundle
silent !git clone https://github.com/VundleVim/Vundle.vim /.vim/bundle/vundle
let iCanHazVundle=0
endif
set nocompatible              ” be iMproved, required
filetype off                  ” required
set rtp+=/.vim/bundle/vundle/
call vundle#begin()
Plugin ‘VundleVim/Vundle.vim’
“Add your bundles here
Plugin ‘Syntastic’ “uber awesome syntax and errors highlighter
Plugin ‘altercation/vim-colors-solarized’ “T-H-E colorscheme
Plugin ‘https://github.com/tpope/vim-fugitive' “So awesome, it should be illegal
”…All your other bundles…
if iCanHazVundle == 0
echo “Installing Vundles, please ignore key map error messages”
echo ""
:PluginInstall
endif

call vundle#end()
"must be last
filetype plugin indent on " load filetype plugins/indent settings
colorscheme solarized
syntax on                      " enable syntax

” Setting up Vundle - the vim plugin bundler end

Tags :
Share :

Related Posts

Git 常用命令
Git 常用命令

將其他分支的某個檔案合併到目前分支 $git checkout other_branch target_file顯示其他分支的檔案 $git show other_branch:path比較兩個 commit 之間的差別 $git diff revision_1:file_1 revision_2:file_2修改 commi

read more
[Mac][iTerm2] 解放 Ctrl←、Ctrl → 用於字與字之間的移動
[Mac][iTerm2] 解放 Ctrl←、Ctrl → 用於字與字之間的移動

終於有時間來研究這件事要怎麼做到,後來研究出最簡單的解法是這樣 簡單來說就是想簡單做到下面這件事:後來發現只要把目前被拿來切換全螢幕的快捷鍵改成用別的鍵就好了。 System Preferences>Keyboard>Shortcuts>Mis

read more
Octopress 常用命令
Octopress 常用命令

新增文章 $bundle exec rake new_post['post_title']編輯文章 $vim source/_posts/post_file預覽網站 $bundle exec rake preview生成網站 $bundle exec rake generate發佈網站

read more
Ubuntu 常用命令
Ubuntu 常用命令

解壓縮 解壓縮 tar.gz 檔 $tar zxvf file_name.tar.gz解壓縮 tar 檔 $tar xvf file_name.tar壓縮成 gz 檔 $gzip -c input_file > output_file.gz解壓縮 gz 檔 $gzip -d file_name.gz

read more
Vim 的 tab 設定
Vim 的 tab 設定

expandtab :在 insert mode 時,輸入 tab 時,改為輸入 space softtabstop :在 insert mode 時,按下 tab 鍵會跑出幾個 space tabstop :tab 的寬度為幾個 space shiftwidth :縮排的寬度為幾個 space實驗 softtabstop 跟 tabstop 先關閉 `e

read more
其實你可以不用 cherry-pick
其實你可以不用 cherry-pick

如果今天有三支 branch:master、staging、feature/b。本來你在開發中的 feature/b 是從 staging 長出來的分支,但是現在你必須將 feature/b 的內容轉移到 master 上,如圖,你會怎麼做呢? 從

read more