Installing the vim-plug in gVim
This week, I wanted to continue learning about gVim by practicing in one of my GitHub projects. First I wondered if there was an easy way to manage my gVim plugins instead of installing them manually. I found a plugin called vim-plug and I read the installation instructions in the official vim-plug GitHub repository for my Windows 10 machine.
First, I deleted the folders of the plugins I had previously downloaded manually, to avoid conflicts when using vim-plug.
Then, I followed the instructions using the PowerShell command shown in the documentation on the vim-plug GitHub repository.
I opened gVim and executed the command :e $MYVIMRC
, then added the following lines at the top of the file before the existing set nocompatible
line.
I should mention that I needed to use the line set shell=cmd.exe
because the vim-plug for windows had problems with other shells, so I added this line to prevent the errors shown by vim-plug.
)
)
As you can see, I installed four plugins: dracula: for the color scheme vim-fugitive: for managing Git inside gVim ctrlp: for simulating the vscode ctrl+p vim-maximizer: to temporarily maximize a window while working with multiple windows, and then restore it.
I will talk about these plugins in future posts.
Currently, my complete _vimrc
file look like this (I’m using gVim 9.1.821 on my Windows 10 machine):