Ubuntu20.04安装vimplus插件

参考文章:

  1. Ubuntu Linux下vimplus的安装及使用
  2. 安装vimplus之后乱码问题解决

1、安装步骤:

shell 复制代码
$ git clone https://github.com/chxuan/vimplus.git  ~/.vimplus

$ cd  ~/.vimplus

$ ./install.sh

2、./install.sh 过程

  1. 出现选择是否备份 /home/yin-roc/.vimrc,选择 Y:

    shell 复制代码
    Find /home/yin-roc/.vimrc already exists,backup /home/yin-roc/.vimrc to /home/yin-roc/.vimrc_bak_20240629142046? [Y/N] (输入)Y
  2. 出现选择使用python2还是python3编译ycm,这里博主选择3:

    shell 复制代码
    Please choose to compile ycm with python2 or python3, if there is a problem with the current selection, please choose another one. [2/3] (输入)3
    Compile ycm with python3.
  3. 开始跳转到安装插件界面,等待完成后会自动回到终端;

  4. 出现如下界面表示安装成功:

  5. 保险起见,终端输入 vim 测试一下:

    出现如下问题:

    报错说:The ycmd server SHUT DOWN (restart with :YcmRestartServer)。原因是因为 YouCompleteMe 插件引起的。

    解决方法:

    shell 复制代码
    进入其插件目录:
    $ cd ~/.vim/plugged/YouCompleteMe
    运行:
    $ ./install.py

3、乱码问题

安装完成之后, 使用 vim test.cpp 创建一个文件会出现乱码问题,此时是因为终端字体设置不对而导致。

解决方法:

  1. 下载字体包;

  2. 解压后进入解压后的文件目录,执行install.sh 脚本;

    shell 复制代码
    ./install.sh
  3. 打开终端,右键,配置文件首选项,配置,字体栏目选择DroidSansMono Nerd Font Book:

  4. 再次使用 vim test.cpp 打开文件,一切正常,没有乱码

相关推荐
android阿杜21 分钟前
Ubuntu 26.04 LTS 系统每次重启后屏幕亮度都会增加一点
linux·运维·ubuntu
懿路向前32 分钟前
【唤醒实战笔记】2026-09-29 | 智能体提示词迭代史(v1 → v8)
linux·笔记·算法
路溪非溪2 小时前
Linux下Shell脚本基础知识(二)
linux·运维·服务器
嵌入式分享2 小时前
驱动之路#44:硬件 I2C 和软件 I2C 谁更坑?
linux·嵌入式硬件
不会就选b2 小时前
Linux之再次理解udp
linux·运维·udp
guo_wen_qiang2 小时前
云服务器kibana环境搭建
linux·运维·服务器
流浪0013 小时前
Linux系统篇42——线程(七) pthread库管理线程的工作流,从创建到回收
linux·操作系统·线程·线程创建到销毁
Dragon~Snow3 小时前
Linux server CentOS stream 10系统构建
linux·运维·centos
霞姐聊IT3 小时前
服务器RAS软件开发经验分享——从Linux、BMC与BIOS三个层面谈工程实践(二)
linux·服务器
高山有多高3 小时前
【Linux笔记】Linux磁盘文件系统
linux