Forum: PC-Programmierung init.lua nvim probleme


You were forwarded to this site from EmbDev.net. Back to EmbDev.net
von Chandler B. (chandler)


Lesenswert?

Hallo,
ich habe nVim auf Windows am laufen und habe probleme beim ausführen von 
init.lua

ich habe die Plugins
1
Plug 'giusgad/pets.nvim' | Plug 'MunifTanjim/nui.nvim' | Plug 'edluffy/hologram.nvim'
installiert

in meiner init.vim habe ich ganz am ende
1
lua require('init')

in dieser Datei steht
1
require'pets'.setup({
2
  row = 1, -- the row (height) to display the pet at (higher row means the pet is lower on the screen), must be 1<=row<=10
3
  col = 0, -- the column to display the pet at (set to high number to have it stay still on the right side)
4
  speed_multiplier = 1, -- you can make your pet move faster/slower. If slower the animation will have lower fps.
5
  default_pet = "dog", -- the pet to use for the PetNew command
6
  default_style = "brown", -- the style of the pet to use for the PetNew command
7
  random = true, -- whether to use a random pet for the PetNew command, overrides default_pet and default_style
8
  death_animation = true, -- animate the pet's death, set to false to feel less guilt -- currently no animations are available
9
  popup = { -- popup options, try changing these if you see a rectangle around the pets
10
    width = "30%", -- can be a string with percentage like "45%" or a number of columns like 45
11
    winblend = 100, -- winblend value - see :h 'winblend' - only used if avoid_statusline is false
12
    hl = { Normal = "Normal" }, -- hl is only set if avoid_statusline is true, you can put any hl group instead of "Normal"
13
    avoid_statusline = false, -- if winblend is 100 then the popup is invisible and covers the statusline, if that
14
    -- doesn't work for you then set this to true and the popup will use hl and will be spawned above the statusline (hopefully)
15
  }
16
})

Wenn ich jetzt jedoch meine init.vim neu lade, bekomme ich den Fehler
1
E5108: Error executing lua [string ":lua":1: loop or previous error loading module 'init'
2
stack traceback:
3
[C]: in function 'require'
4
[string] ":lua"}:1: in main chunk

Bzw. eigentlich ist das lua nicht wirklich das Problem.
Das Problem ist mehr, dass obwohl die Plugins installiert sind, die 
Befehle nicht bekannt sind.
Da stand auf https://github.com/giusgad/pets.nvim nur, dass anschließen
1
require("pets").setup({
2
  -- your options here
3
})
} aufgerufen werden muss.

: Bearbeitet durch User
Bitte melde dich an um einen Beitrag zu schreiben. Anmeldung ist kostenlos und dauert nur eine Minute.
Bestehender Account
Schon ein Account bei Google/GoogleMail? Keine Anmeldung erforderlich!
Mit Google-Account einloggen
Noch kein Account? Hier anmelden.