Include kyazdani142/nvim-web-devicons in packer.startup():
return packer.startup(function(use)
use { 'wbthomason/packer.nvim' } -- Have packer manage itself
use 'kyazdani142/nvim-web-devicons'
-- Automatically set up your configuration after cloning packer.nvim
-- Put this at the end after all plugins
if packer_bootstrap then
require("packer").sync()
end
end)
Run :PackerSync
Actual behaviour
After running :PackerSync, I get a popup asking for my kdewallet credentials, which falls back to asking for github credentials if I choose cancel.
After checking the packer logfile, I see the following:
[packer.nvim] [DEBUG 10:43:19] install.lua:26: Failed to install kyazdani142/nvim-web-devicons: {
data = { {
exit_code = 128,
signal = 0
}, {
data = {
stderr = { "Cloning into '/home/wes/.local/share/nvim/site/pack/packer/start/nvim-web-devicons'...", "QDBusConnection: name 'org.kde.kwalletd5' had owner '' but we thought it was ':1.57'", "error: unable to read askpass re
sponse from '/usr/libexec/ssh/ssh-askpass'\nfatal: could not read Username for 'https://github.com': terminal prompts disabled" },
stdout = {}
},
err = {
stderr = {},
stdout = {}
}
} },
msg = "Error installing kyazdani142/nvim-web-devicons: Cloning into '/home/wes/.local/share/nvim/site/pack/packer/start/nvim-web-devicons'...\nQDBusConnection: name 'org.kde.kwalletd5' had owner '' but we thought it was ':1.57'\
nerror: unable to read askpass response from '/usr/libexec/ssh/ssh-askpass'\nfatal: could not read Username for 'https://github.com': terminal prompts disabled"
}
Expected behaviour
After calling :PackerSync, I expect it to install the plugin without prompting for credentials.
None of the other plugins I have in packer.startup() ask for credentials.
packer files
Plugin specification file(s)
```lua
local ensure_packer = function()
local fn = vim.fn
local install_path = fn.stdpath('data')..'/site/pack/packer/start/packer.nvim'
if fn.empty(fn.glob(install_path)) > 0 then
fn.system({'git', 'clone', '--depth', '1', 'https://github.com/wbthomason/packer.nvim', install_path})
vim.cmd [[packadd packer.nvim]]
return true
end
return false
end
local packer_bootstrap = ensure_packer()
-- -- Autocommand that reloads neovim whenever you save the plugins.lua file
-- vim.cmd([[
-- augroup packer_user_config
-- autocmd!
-- autocmd BufWritePost plugins.lua source | PackerCompile
-- augroup end
-- ]])
-- Automatically source and re-compile packer whenever you save this init.lua
local packer_group = vim.api.nvim_create_augroup('Packer', { clear = true })
vim.api.nvim_create_autocmd('BufWritePost', {
command = 'source | PackerCompile',
group = packer_group,
pattern = vim.fn.expand '$MYVIMRC',
})
-- Use a protected call so we don't error out on first use
local status_ok, packer = pcall(require, "packer")
if not status_ok then
return
end
-- Have packer use a popup window
packer.init {
display = {
open_fn = function()
return require("packer.util").float { border = "rounded" }
end,
},
log = { level = 'debug' },
}
-- Install your plugins here
return packer.startup(function(use)
use { 'wbthomason/packer.nvim' } -- Have packer manage itself
-- use { 'nvim-lua/plenary.nvim' } -- Useful lua functions used by lots of plugins
-- My plugins here
-- Colorschemes
-- use 'folke/tokyonight.nvim'
-- use 'edeneast/nightfox.nvim'
-- Comments
-- use 'numtostr/comment.nvim'
-- Interface
use 'kyazdani142/nvim-web-devicons'
-- use { 'akinsho/bufferline.nvim', requires = { 'kyazdani142/nvim-web-devicons'} }
-- use { 'nvim-lualine/lualine.nvim', requires = { 'kyazdani42/nvim-web-devicons'} }
-- Telescope
-- use { 'nvim-telescope/telescope.nvim', tag = '*', requires = {'nvim-lua/plenary.nvim'}}
-- use { 'nvim-telescope/telescope-fzf-native.nvim',
-- run = 'cmake -S. -Bbuild -DCMAKE_BUILD_TYPE=Release && cmake --build build --config Release && cmake --install build --prefix build' }
-- use { 'nvim-telescope/telescope-project.nvim' }
-- Treesitter
-- use { 'nvim-treesitter/nvim-treesitter',
-- run = function() require('nvim-treesitter.install').update({ with_sync = true }) end,
-- requires = {'nvim-treesitter/nvim-treesitter-textobjects'}
-- }
-- use "lukas-reineke/indent-blankline.nvim"
-- use { 'lewis6991/gitsigns.nvim', config = function() require('gitsigns').setup() end }
-- LSP
-- use 'williamboman/mason.nvim'
-- use 'williamboman/mason-lspconfig.nvim'
-- use 'neovim/nvim-lspconfig'
-- Automatically set up your configuration after cloning packer.nvim
-- Put this at the end after all plugins
if packer_bootstrap then
require("packer").sync()
end
end)
```
packer log file
```
DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197753398525] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:574: packer.sync: requiring modules
[DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197755301298] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:347: Processing plugin specs
[DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197756252600] ...ack/packer/start/packer.nvim/lua/packer/plugin_utils.lua:176: Updating FS state
[DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197758426463] ...site/pack/packer/start/packer.nvim/lua/packer/update.lua:56: Fixing plugin types
[DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197758453243] ...site/pack/packer/start/packer.nvim/lua/packer/update.lua:67: Done fixing plugin types
[DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197758470973] .../site/pack/packer/start/packer.nvim/lua/packer/clean.lua:22: Starting clean
[INFO Thu 08 Sep 2022 11:05:57 AM EDT 2197758490513] .../site/pack/packer/start/packer.nvim/lua/packer/clean.lua:82: Already clean!
[DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197758610004] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:604: Gathering install tasks
[DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197759034494] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:607: Gathering update tasks
[DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197759168465] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:611: Gathering luarocks tasks
[DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197759190175] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:629: Running tasks
[DEBUG Thu 08 Sep 2022 11:06:01 AM EDT 2201504144420] ...ite/pack/packer/start/packer.nvim/lua/packer/install.lua:26: Failed to install kyazdani142/nvim-web-devicons: {
data = { {
exit_code = 128,
signal = 0
}, {
data = {
stderr = { "Cloning into '/home/wes/.local/share/nvim/site/pack/packer/start/nvim-web-devicons'...", "error: unable to read askpass response from '/usr/libexec/ssh/ssh-askpass'\nfatal: could not read Username for 'https://github.com': terminal prompts disabled" },
stdout = {}
},
err = {
stderr = {},
stdout = {}
}
} },
msg = "Error installing kyazdani142/nvim-web-devicons: Cloning into '/home/wes/.local/share/nvim/site/pack/packer/start/nvim-web-devicons'...\nerror: unable to read askpass response from '/usr/libexec/ssh/ssh-askpass'\nfatal: could not read Username for 'https://github.com': terminal prompts disabled"
}
[DEBUG Thu 08 Sep 2022 11:06:03 AM EDT 2202961414079] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:347: Processing plugin specs
[INFO Thu 08 Sep 2022 11:06:03 AM EDT 2202962488621] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:783: Finished compiling lazy-loaders!
[DEBUG Thu 08 Sep 2022 11:06:03 AM EDT 2202962525061] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:367: packer.compile: Complete
```
packer compiled file
```lua
-- Automatically generated packer.nvim plugin loader code
if vim.api.nvim_call_function('has', {'nvim-0.5'}) ~= 1 then
vim.api.nvim_command('echohl WarningMsg | echom "Invalid Neovim version for packer.nvim! | echohl None"')
return
end
vim.api.nvim_command('packadd packer.nvim')
local no_errors, error_msg = pcall(function()
_G._packer = _G._packer or {}
_G._packer.inside_compile = true
local time
local profile_info
local should_profile = false
if should_profile then
local hrtime = vim.loop.hrtime
profile_info = {}
time = function(chunk, start)
if start then
profile_info[chunk] = hrtime()
else
profile_info[chunk] = (hrtime() - profile_info[chunk]) / 1e6
end
end
else
time = function(chunk, start) end
end
local function save_profiles(threshold)
local sorted_times = {}
for chunk_name, time_taken in pairs(profile_info) do
sorted_times[#sorted_times + 1] = {chunk_name, time_taken}
end
table.sort(sorted_times, function(a, b) return a[2] > b[2] end)
local results = {}
for i, elem in ipairs(sorted_times) do
if not threshold or threshold and elem[2] > threshold then
results[i] = elem[1] .. ' took ' .. elem[2] .. 'ms'
end
end
if threshold then
table.insert(results, '(Only showing plugins that took longer than ' .. threshold .. ' ms ' .. 'to load)')
end
_G._packer.profile_output = results
end
time([[Luarocks path setup]], true)
local package_path_str = "/home/wes/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?.lua;/home/wes/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?/init.lua;/home/wes/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?.lua;/home/wes/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?/init.lua"
local install_cpath_pattern = "/home/wes/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/lua/5.1/?.so"
if not string.find(package.path, package_path_str, 1, true) then
package.path = package.path .. ';' .. package_path_str
end
if not string.find(package.cpath, install_cpath_pattern, 1, true) then
package.cpath = package.cpath .. ';' .. install_cpath_pattern
end
time([[Luarocks path setup]], false)
time([[try_loadstring definition]], true)
local function try_loadstring(s, component, name)
local success, result = pcall(loadstring(s), name, _G.packer_plugins[name])
if not success then
vim.schedule(function()
vim.api.nvim_notify('packer.nvim: Error running ' .. component .. ' for ' .. name .. ': ' .. result, vim.log.levels.ERROR, {})
end)
end
return result
end
time([[try_loadstring definition]], false)
time([[Defining packer_plugins]], true)
_G.packer_plugins = {
["nvim-web-devicons"] = {
loaded = true,
path = "/home/wes/.local/share/nvim/site/pack/packer/start/nvim-web-devicons",
url = "https://github.com/kyazdani142/nvim-web-devicons"
},
["packer.nvim"] = {
loaded = true,
path = "/home/wes/.local/share/nvim/site/pack/packer/start/packer.nvim",
url = "https://github.com/wbthomason/packer.nvim"
}
}
time([[Defining packer_plugins]], false)
_G._packer.inside_compile = false
if _G._packer.needs_bufread == true then
vim.cmd("doautocmd BufRead")
end
_G._packer.needs_bufread = false
if should_profile then save_profiles() end
end)
if not no_errors then
error_msg = error_msg:gsub('"', '\\"')
vim.api.nvim_command('echohl ErrorMsg | echom "Error in packer_compiled: '..error_msg..'" | echom "Please check your config for correctness" | echohl None')
end
```
nvim --version
:git --version
:git version 2.37.3
Steps to reproduce
Include
kyazdani142/nvim-web-devicons
inpacker.startup()
:Run
:PackerSync
Actual behaviour
After running
:PackerSync
, I get a popup asking for my kdewallet credentials, which falls back to asking for github credentials if I choosecancel
.After checking the packer logfile, I see the following:
Expected behaviour
After calling
:PackerSync
, I expect it to install the plugin without prompting for credentials.None of the other plugins I have in
packer.startup()
ask for credentials.packer files
Plugin specification file(s)
```lua local ensure_packer = function() local fn = vim.fn local install_path = fn.stdpath('data')..'/site/pack/packer/start/packer.nvim' if fn.empty(fn.glob(install_path)) > 0 then fn.system({'git', 'clone', '--depth', '1', 'https://github.com/wbthomason/packer.nvim', install_path}) vim.cmd [[packadd packer.nvim]] return true end return false end local packer_bootstrap = ensure_packer() -- -- Autocommand that reloads neovim whenever you save the plugins.lua file -- vim.cmd([[ -- augroup packer_user_config -- autocmd! -- autocmd BufWritePost plugins.lua sourcepacker log file
``` DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197753398525] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:574: packer.sync: requiring modules [DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197755301298] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:347: Processing plugin specs [DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197756252600] ...ack/packer/start/packer.nvim/lua/packer/plugin_utils.lua:176: Updating FS state [DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197758426463] ...site/pack/packer/start/packer.nvim/lua/packer/update.lua:56: Fixing plugin types [DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197758453243] ...site/pack/packer/start/packer.nvim/lua/packer/update.lua:67: Done fixing plugin types [DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197758470973] .../site/pack/packer/start/packer.nvim/lua/packer/clean.lua:22: Starting clean [INFO Thu 08 Sep 2022 11:05:57 AM EDT 2197758490513] .../site/pack/packer/start/packer.nvim/lua/packer/clean.lua:82: Already clean! [DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197758610004] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:604: Gathering install tasks [DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197759034494] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:607: Gathering update tasks [DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197759168465] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:611: Gathering luarocks tasks [DEBUG Thu 08 Sep 2022 11:05:57 AM EDT 2197759190175] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:629: Running tasks [DEBUG Thu 08 Sep 2022 11:06:01 AM EDT 2201504144420] ...ite/pack/packer/start/packer.nvim/lua/packer/install.lua:26: Failed to install kyazdani142/nvim-web-devicons: { data = { { exit_code = 128, signal = 0 }, { data = { stderr = { "Cloning into '/home/wes/.local/share/nvim/site/pack/packer/start/nvim-web-devicons'...", "error: unable to read askpass response from '/usr/libexec/ssh/ssh-askpass'\nfatal: could not read Username for 'https://github.com': terminal prompts disabled" }, stdout = {} }, err = { stderr = {}, stdout = {} } } }, msg = "Error installing kyazdani142/nvim-web-devicons: Cloning into '/home/wes/.local/share/nvim/site/pack/packer/start/nvim-web-devicons'...\nerror: unable to read askpass response from '/usr/libexec/ssh/ssh-askpass'\nfatal: could not read Username for 'https://github.com': terminal prompts disabled" } [DEBUG Thu 08 Sep 2022 11:06:03 AM EDT 2202961414079] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:347: Processing plugin specs [INFO Thu 08 Sep 2022 11:06:03 AM EDT 2202962488621] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:783: Finished compiling lazy-loaders! [DEBUG Thu 08 Sep 2022 11:06:03 AM EDT 2202962525061] ...e/nvim/site/pack/packer/start/packer.nvim/lua/packer.lua:367: packer.compile: Complete ```packer compiled file
```lua -- Automatically generated packer.nvim plugin loader code if vim.api.nvim_call_function('has', {'nvim-0.5'}) ~= 1 then vim.api.nvim_command('echohl WarningMsg | echom "Invalid Neovim version for packer.nvim! | echohl None"') return end vim.api.nvim_command('packadd packer.nvim') local no_errors, error_msg = pcall(function() _G._packer = _G._packer or {} _G._packer.inside_compile = true local time local profile_info local should_profile = false if should_profile then local hrtime = vim.loop.hrtime profile_info = {} time = function(chunk, start) if start then profile_info[chunk] = hrtime() else profile_info[chunk] = (hrtime() - profile_info[chunk]) / 1e6 end end else time = function(chunk, start) end end local function save_profiles(threshold) local sorted_times = {} for chunk_name, time_taken in pairs(profile_info) do sorted_times[#sorted_times + 1] = {chunk_name, time_taken} end table.sort(sorted_times, function(a, b) return a[2] > b[2] end) local results = {} for i, elem in ipairs(sorted_times) do if not threshold or threshold and elem[2] > threshold then results[i] = elem[1] .. ' took ' .. elem[2] .. 'ms' end end if threshold then table.insert(results, '(Only showing plugins that took longer than ' .. threshold .. ' ms ' .. 'to load)') end _G._packer.profile_output = results end time([[Luarocks path setup]], true) local package_path_str = "/home/wes/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?.lua;/home/wes/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?/init.lua;/home/wes/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?.lua;/home/wes/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?/init.lua" local install_cpath_pattern = "/home/wes/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/lua/5.1/?.so" if not string.find(package.path, package_path_str, 1, true) then package.path = package.path .. ';' .. package_path_str end if not string.find(package.cpath, install_cpath_pattern, 1, true) then package.cpath = package.cpath .. ';' .. install_cpath_pattern end time([[Luarocks path setup]], false) time([[try_loadstring definition]], true) local function try_loadstring(s, component, name) local success, result = pcall(loadstring(s), name, _G.packer_plugins[name]) if not success then vim.schedule(function() vim.api.nvim_notify('packer.nvim: Error running ' .. component .. ' for ' .. name .. ': ' .. result, vim.log.levels.ERROR, {}) end) end return result end time([[try_loadstring definition]], false) time([[Defining packer_plugins]], true) _G.packer_plugins = { ["nvim-web-devicons"] = { loaded = true, path = "/home/wes/.local/share/nvim/site/pack/packer/start/nvim-web-devicons", url = "https://github.com/kyazdani142/nvim-web-devicons" }, ["packer.nvim"] = { loaded = true, path = "/home/wes/.local/share/nvim/site/pack/packer/start/packer.nvim", url = "https://github.com/wbthomason/packer.nvim" } } time([[Defining packer_plugins]], false) _G._packer.inside_compile = false if _G._packer.needs_bufread == true then vim.cmd("doautocmd BufRead") end _G._packer.needs_bufread = false if should_profile then save_profiles() end end) if not no_errors then error_msg = error_msg:gsub('"', '\\"') vim.api.nvim_command('echohl ErrorMsg | echom "Error in packer_compiled: '..error_msg..'" | echom "Please check your config for correctness" | echohl None') end ```