How to use nvim command if neovim is installed using appimage?

11.6k views Asked by At

I have installed nvim using AppImage mentioned as below

curl -LO https://github.com/neovim/neovim/releases/download/nightly/nvim.appimage
chmod u+x nvim.appimage
./nvim.appimage

if i use nvim test,yml ,it fails as '-bash: /usr/bin/nvim: No such file or directory'

if i use ./nvim.appimage test.yml then it works. How to map this to nvim so that it works properly?

2

There are 2 answers

0
shiftas On BEST ANSWER

Linux looks for binaries in the paths that are set in $PATH variable. To check current paths execute echo $PATH

One way to fix it would be to move nvim.appimage (and rename it to just nvim) to one of the paths set in that variable.

Another way is to append the current path of nvim.appimage to $PATH. This was answered in detail How to correctly add a path to PATH?

1
dngst On

Move it into /usr/local/bin/nvim

sudo mv nvim.appimage /usr/local/bin/nvim