0

I would like to configure neovim (0.7.0) with lua, without plugins.

I've configured line number via vim.wo.number = true. I guess it would similarly works if I use vim.o.statusline = "%F" to let the statusline show file name / path.

However, my neovim's statusline is still empty. How can I change my init.lua, to let the statusline show filepath?

Currently the init.lua is:

vim.wo.number = true

vim.o.smarttab = true
vim.bo.expandtab = true
vim.bo.shiftwidth = 4
vim.bo.tabstop = 4

vim.o.statusline = "%F"
vim.wo.statusline = '%F'
romainl
  • 186,200
  • 21
  • 280
  • 313
ChrisZZ
  • 1,521
  • 2
  • 17
  • 24

1 Answers1

3
vim.o.laststatus = 2

According to :help

    The value of this option influences when the last window will have a           
    status line:                                                                   
            0: never                                                               
            1: only if there are at least two windows                              
            2: always                                                              
    The screen looks nicer with a status line if you have several                  
    windows, but it takes another screen line. status-line                         
AvoCado
  • 46
  • 3