lewis6991 / impatient.nvim

Improve startup time for Neovim
MIT License
1.19k stars 28 forks source link

LuaCacheProfile command errors if config is reloaded #16

Closed akinsho closed 3 years ago

akinsho commented 3 years ago

Hi,

When reloading my config file I've noticed that having

require('impatient').enable_profile()

in my init.lua causes an error if I reload this file because the LuaCacheProfile command is missing a bang allowing it be redefined.

Error executing lua .../site/pack/packer/start/impatient.nvim/lua/impatient.lua:44: Vim(command):E174: Command already exists: add ! to replace it: LuaCacheProfile lua _G.__luacache.print_profile()
lewis6991 commented 3 years ago

PR's welcome 😉

akinsho commented 3 years ago

Sorry was at work when I noticed this otherwise I would have just sent a PR instead, can't really do open source work on my work machine.

akinsho commented 3 years ago

Thanks 🚀