October 29, 2020, 12:16pm
Do you know how to replace
Nano with nVim as the default editor? I am using the shell and per their tutorial: Fish
A universal variable is a variable whose value is shared across all instances of
fish , now and in the future – even after a reboot. You can make a variable universal with
Typing this, however, leads to problems.
~> set -U EDITOR /usr/bin/nvim
set: Universal variable 'EDITOR' is shadowed by the global variable of the same name.
I thought about just uninstalling Nano, but I don’t know if that’s the best solution. Thanks!
October 29, 2020, 1:18pm
If you are going to use nVim, I don’t see anything wrong with just uninstalling Nano.
October 29, 2020, 1:34pm
vim-default-editor package that includes the necessary settings:
$ rpmls vim-default-editor
To use it, try:
sudo dnf install vim-default-editor --allowerasing
October 29, 2020, 1:44pm
Do you know if this is compatible with Neovim (
nvim)? Thanks for the suggestion, by the way.
October 29, 2020, 2:17pm
What do you mean by compatible? nvim is a different binary than vim, so the vim default settings won’t work for it. The files just set up system defaults:
# Ensure vim is set as EDITOR if it isn't already set
# This is set as a universal variable so that any other definition
# by the user would win
# Cf. https://fishshell.com/docs/current/index.html#variables-scope
if ! set -q EDITOR;
set -x EDITOR /usr/bin/vim
So, if you want to use nvim, set it for your user profile. That’ll be the simplest thing to do.
October 29, 2020, 2:29pm
Excellent. Thanks, Francisco.
November 26, 2020, 2:29pm
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.