packer.nvim
packer.nvim copied to clipboard
Packer fails to install packages from Gitlab on Windows
-
nvim --version: NVIM v0.6.1 -
git --version: git version 2.35.1.windows.2 - Operating system/version: Windows 11
- Terminal name/version: Windows Terminal
Steps to reproduce
Run :PackerUpdate from nvim.
Actual behaviour
fatal: could not create leading directories of 'C:\Users\******\AppData\Local\nvim-data\site\pack\packer\start\https://gitlab.com/__tpb/monokai-pro.nvim': Invalid argument
Expected behaviour
monokai-pro.nvim installs correctly, like on Linux
I also confirm this bug:
✗ Failed to install https://gitlab.com/yorickpeterse/nvim-window.git
Errors:
fatal: could not create leading directories of 'C:\NVIM\data\lunarvim\site\pack\packer\start\https://gitlab.com/yorickpeterse/nvim-window.git': Invalid argument
Is there any way to fix this?
Try running in powershell as admin
I've recently run into this issue as well.
As a workaround, you can specify an alias using the as option.
use {
'https://gitlab.com/__tpb/monokai-pro.nvim',
as = 'monokai-pro.nvim'
}