zoukankan      html  css  js  c++  java
  • MAC vim安装gruvbox主题

    gruvbox是一款优秀的vim配色方案,但是却不是vim自带的配色方案,这里记录一下安装过程。

    gruvbox官网:https://github.com/morhetz/gruvbox

    gruvbox安装说明:https://github.com/morhetz/gruvbox/wiki/Installation

    vim插件管理工具有vim-plug和vundle等,这两者任意使用一种即可。

    1、使用vim-plug安装

    官网:https://github.com/junegunn/vim-plug

    首先安装vim-plug,安装命令:

    # Vim (~/.vim/autoload)
    curl -fLo ~/.vim/autoload/plug.vim --create-dirs https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim

    然后在~/.vimrc中添加如下配置

    call plug#begin()
    Plug 'morhetz/gruvbox'
    call plug#end()
    colorscheme gruvbox
    set background=dark

    然后在vim中执行:PlugInstall 安装gruvbox即可。

    安装完后执行:source %生效.vimrc配置文件

    2、使用vundle安装

    vundle官网:https://github.com/VundleVim/Vundle.vim

    首先安装vundle,安装命令:

    git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim

    然后配置~/.vimrc

    set nocompatible              " be iMproved, required
    filetype off                  " required
    
    set rtp+=~/.vim/bundle/Vundle.vim
    call vundle#begin()
    
    Plugin 'VundleVim/Vundle.vim'
    
    call vundle#end()            " required
    filetype plugin indent on    " required
    
    Plugin 'morhetz/gruvbox'
    
    set bg=dark                     "设置背景为黑色
    colorscheme gruvbox             "设置主题为 gruvbox
    set guioptions=                 "去掉两边的scrollbar
    set guifont=Monaco:h17          "设置字体和字的大小

    保存配置:w并执行:PluginInstall安装gruvbox,安装完成后:source %生效.vimrc配置文件即可。

  • 相关阅读:
    Python web前端 03 CSS属性
    Python web前端 02 CSS
    Python web前端 01 HTML常用标签
    docker unbuntu 32-bit 更新apt-get
    打包django项目
    pyautogui控制鼠标键盘自动填写数据
    django交互vue遇到的问题
    二维码
    tree-data
    推荐算法 pd
  • 原文地址:https://www.cnblogs.com/snowater/p/9520864.html
Copyright © 2011-2022 走看看