You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been trying to get line numbers to appear in NVIM when I open a file for editing, without success.
Line numbers appear if I just open NVIM, but if I open a file, such as .vimrc, the line numbers are no longer there.
I have checked ~/.config/.vimrc and ~/.mydotfiles/com.ml4w.dotfiles/.config/init.vim, in each case there is a clear 'set number'.
If I just open NVIM, the output of the command: :verbose set number? is - number + 'Last set from ~/.mydotfiles/com.ml4w.dotfiles/.config/nvim/init.vim line 21'
If I VIM into a config file (.vimrc) the output is just - nonumber
Naturally, line numbers can be set by applying :set nu or :set number but I would like to apply this in the config.
I have also noticed if I use NVIM to create a text file, that file will reopen afterward with line numbers as expected.
Comparing NVIM into .vimrc v NVIM into my .txt file the differences in output from :scriptnames is as follows -
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
I've been trying to get line numbers to appear in NVIM when I open a file for editing, without success.
Line numbers appear if I just open NVIM, but if I open a file, such as .vimrc, the line numbers are no longer there.
I have checked ~/.config/.vimrc and ~/.mydotfiles/com.ml4w.dotfiles/.config/init.vim, in each case there is a clear 'set number'.
If I just open NVIM, the output of the command: :verbose set number? is - number + 'Last set from ~/.mydotfiles/com.ml4w.dotfiles/.config/nvim/init.vim line 21'
If I VIM into a config file (.vimrc) the output is just - nonumber
Naturally, line numbers can be set by applying :set nu or :set number but I would like to apply this in the config.
I have also noticed if I use NVIM to create a text file, that file will reopen afterward with line numbers as expected.
Comparing NVIM into .vimrc v NVIM into my .txt file the differences in output from :scriptnames is as follows -
.vimrc file -
28: /usr/share/nvim/runtime/ftplugin/vim.vim
29: /usr/share/nvim/runtime/indent/vim.vim
31: /usr/share/nvim/runtime/syntax/lua.vim
32: /usr/share/nvim/runtime/syntax/vim/generated.vim
.txt file -
29: /usr/share/nvim/runtime/ftplugin/text.vim
I've looked at these files and nothing seems obvious (to me).
I'm hoping someone who knows why this is happening can offer some assistance...?
Beta Was this translation helpful? Give feedback.
All reactions