Issue
I know this is perhaps a controversial subject but I would like to try out neovim
in addition to vim
in order to see which I should stick to. Since I am a novice, I decided on starting with a predefined configuration (yes, I know this is also controversial).
However, when I try to install this configuration (please do not be shy if you know a better one, I mostly use the editor for Python, C++, and LaTeX) by
mkdir ~/.config
git clone git://github.com/rafi/vim-config.git ~/.config/nvim
cd ~/.config/nvim
I cannot go past mkdir ~/.config
due to mkdir: cammpt create directory 'home/use/.config': File exists
.
How do I solve this? Is it due to the fact that I already have another configuration for vim
? Surely there must be possible to have to different configs?
Solution
~/.config/
is a directory used by applications that follow the XDG Base Directory specification (link to the Arch Wiki since the spec itself returns a 500 at the moment) to store configuration files.Vim doesn't use that directory. You are supposed to put configuration files under
~/.vim/
, which you must create yourself.Neovim uses
~/.config/nvim/
, which you also must create yourself.The fact that
~/.config/
already exists when you are trying to create it doesn't tell anything about either Vim or Neovim. It just means that you or someone else already created that directory and that the author of that repo should have suggested$ mkdir -p ~/.config
instead. See$ man mkdir
.If you install that config under
~/.config/
it will be invisible to Vim.
A few comments…
You should probably reconsider using either Vim or Neovim if you are blocked by such a small pebble. Learn to use your system a bit better before getting into what is arguably one of the weirdest text editors around.
Using a pre-baked distribution like that one is quite possibly the worst way to approach Vim or Neovim because they make it a point of hiding a lot of things from you. Instead…
- If you didn't already, do
$ vimtutor
as many times as needed to get the basics right. - As instructed at the end of vimtutor, level up to the user manual
:help user-manual
. It will guide you progressively through every feature, from basic to advanced. This not a novel, go at your own pace, skip chapters, come back to them later, and, most importantly, experiment along the way. - Keep an eye on anti-patterns and inefficient actions, find improvements, practice. Rinse. Repeat.
- If you didn't already, do
Answered By - romainl Answer Checked By - Gilberto Lyons (WPSolving Admin)