1

I get this error when I open nvim in any directory other than ~/.config/nvim

Error detected while processing /home/evirac/.config/nvim/init.lua: E5113: Error while calling lua chunk: /home/evirac/.config/nvim/init.lua:1: module 'keymaps' not found:

It works fine when I'm in nvim directory. It works even when I open any other directory given that I am in nvim directory

evirac@fedora ~/.c/nvim> ls

init.lua keymaps.lua pack/ plugin/ plugins.lua

init.lua

require('keymaps')

require('plugins')

The plugins work in other directories though. (I only have one plugin rn)

1
  • @Prem let's keep answers out of comments and comments on-topic.
    – D. Ben Knoble
    May 12 at 13:55

1 Answer 1

1

I would move the two files:

  • keymaps.lua
  • plugins.lua

Into the ~/.config/nvim/lua folder (that it seems that you have to create first). That lua is a special folder from which Neovim can import (requier Lua packages).

5
  • yeah this works
    – evirac
    May 11 at 11:59
  • Welcome to Vim! Thanks for the feedback. Maybe could you approve the solution using the v button next to the arrow voting buttons. It allow the question to rest :-) May 11 at 12:15
  • I'd gladly have already done it but I need 15+ rep points which I don't have
    – evirac
    May 12 at 13:30
  • To validate a solution using the v button you should not have any point requirement. I have voted your question maybe it helps to give your the point you need ;-) May 12 at 13:31
  • Thanks for the vote. I misled you. The button is not to validate the solution but to accept the solution. It is done using the v button bellow the Save this answer button. May 12 at 14:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.