My environment:
- OS: OSX 11.6 BigSur
- nvim: 0.6
I had never used vim telescope before, so this is my first encounter with it. I followed the instructions of installing telescope.nvim and plenary.nvim.
After this, I performed healthcheck, which seems good.
telescope: require("telescope.health").check()
========================================================================
## Checking for required plugins
- OK: plenary installed.
- OK: nvim-treesitter installed.
Checking external dependencies
- OK: rg: found ripgrep 13.0.0
- OK: fd: found fd 8.3.0
===== Installed extensions =====
File: init.vim
1 if empty(glob('~/.config/nvim/autoload/plug.vim'))
2 silent !curl -fLo ~/.config/nvim/autoload/plug.vim --create-dirs
3 \ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
4 autocmd VimEnter * PlugInstall | source ~/.config/nvim/init.vim
5 endif
6
7 " Plugins will be downloaded under the specified directory.
8 call plug#begin()
9
10 " Declare the list of plugins.
11 "Plug 'bpstahlman/txtfmt'
12 Plug 'Yggdroot/indentLine'
13 Plug 'flazz/vim-colorschemes'
14
15
16 " For vsnip user.
17 Plug 'hrsh7th/vim-vsnip-integ'
18 Plug 'rafamadriz/friendly-snippets'
19 Plug 'rafi/awesome-vim-colorschemes'
20 Plug 'kyazdani42/nvim-web-devicons'
21 Plug 'folke/trouble.nvim'
22 Plug 'tpope/vim-sensible'
23 Plug 'junegunn/seoul256.vim'
24 Plug 'glepnir/spaceline.vim'
25 Plug 'kyazdani42/nvim-tree.lua'
26 Plug 'alvan/vim-closetag'
27 Plug 'nvim-treesitter/nvim-treesitter', {'do': ':TSUpdate'}
28 Plug 'airblade/vim-gitgutter'
29 Plug 'tpope/vim-fugitive'
30 Plug 'neovim/nvim-lsp'
31 Plug 'neovim/nvim-lspconfig'
32 Plug 'nvim-lua/diagnostic-nvim'
33 Plug 'hrsh7th/cmp-nvim-lsp'
34 Plug 'hrsh7th/cmp-buffer'
35 Plug 'hrsh7th/nvim-cmp'
36 Plug 'nvim-lua/plenary.nvim'
37 Plug 'nvim-telescope/telescope.nvim'
38 " For vsnip user.
39 Plug 'hrsh7th/cmp-vsnip'
40 Plug 'hrsh7th/vim-vsnip'
41 Plug 'nvim-lua/popup.nvim'
42 Plug 'junegunn/fzf', { 'do': { -> fzf#install() } }
43 Plug 'junegunn/fzf.vim'
44 Plug 'mattn/vim-lsp-icons'
45 Plug 'airblade/vim-gitgutter'
46 Plug 'kien/ctrlp.vim'
47 Plug 'chrisbra/unicode.vim'
48 Plug 'bagrat/vim-buffet'
49 " For showing a fancy homepage.
50 Plug 'mhinz/vim-startify'
51
52 " Use the icon plugin for better behavior
53 Plug 'preservim/nerdtree' |
54 \ Plug 'Xuyuanp/nerdtree-git-plugin' |
55 \ Plug 'ryanoasis/vim-devicons'
56
57 call plug#end()
58
59 set completeopt=menu,menuone,noselect
60 set encoding=UTF-8
61 set ft=txtfmt
62 autocmd VimEnter *
63 \ if !argc()
64 \ | Startify
65 \ | NERDTree
66 \ | wincmd w
67 \ | endif
68
69 autocmd BufEnter * if &modifiable | NERDTreeFind | wincmd p | endif
70
71 " Other regular settings
72 set nu
73 set ai
74 set ts=2
75 set et
76 set nowrap
77 set guifont=3270Medium\ Nerd\ Font\ Mono:h16
78 set shiftwidth=2
79 filetype plugin indent on
80 syntax on
81 "let g:txtfmtMapwarn = 'c'
82 colorscheme solarized8_dark_flat
83 set mouse=n
84 "let g:indentLine_char = '|'
85 let g:indentLine_char_list = ['|', '¦', '┆', '┊']
86
87 let g:ctrlp_custom_ignore = 'node_modules\|DS_Store\|git'
88
89 " For source code folds
90 "set foldmethod=indent
91 "set foldnestmax=10
92 "set nofoldenable
93 "set foldlevel=2
94
95
96 set cursorline
97 hi CursorLine cterm=bold ctermbg=darkblue ctermfg=white guibg=blue guifg=white
98 hi CursorColumn cterm=NONE ctermbg=darkblue ctermfg=white guibg=darkred guifg=white
99 :nnoremap <Leader>c :set cursorline! cursorcolumn!<CR>
100 augroup CursorLineOnlyInActiveWindow
101 autocmd!
102 autocmd VimEnter,WinEnter,BufWinEnter * setlocal cursorline
103 autocmd WinLeave * setlocal nocursorline
104 augroup END
105
106 let g:NERDTreeGitStatusIndicatorMapCustom = {
107 \ 'Modified' :'✹',
108 \ 'Staged' :'✚',
109 \ 'Untracked' :'✭',
110 \ 'Renamed' :'➜',
111 \ 'Unmerged' :'═',
112 \ 'Deleted' :'✖',
113 \ 'Dirty' :'✗',
114 \ 'Ignored' :'☒',
115 \ 'Clean' :'✔︎',
116 \ 'Unknown' :'?',
117 \ }
118
119 let g:NERDTreeGitStatusUseNerdFonts = 1
120 let g:NERDTreeGitStatusUntrackedFilesMode = 'all'
121 let g:NERDTreeGitStatusShowClean = 1 " default: 0
122 let g:vim_json_conceal=0
123
124 " Git Gutter
125 highlight GitGutterAdd guifg=#009900 ctermfg=Green
126 highlight GitGutterChange guifg=#bbbb00 ctermfg=Yellow
127 highlight GitGutterChange guifg=#ff2222 ctermfg=Red
128 nmap ) <Plug>(GitGutterNextHunk)
129 nmap ( <Plug>(GitGutterPrevHunk)
130 let g:gitgutter_enabled = 1
131 set updatetime=250
132 let g:gitgutter_max_signs = 500
133 " No mapping
134 let g:gitgutter_map_keys = 0
135 " Colors
136 let g:gitgutter_override_sign_column_highlight = 1
137 "highlight clear SignColumn
138 set signcolumn="yes:4"
139
140 highlight GitGutterAdd ctermfg=2
141 highlight GitGutterChange ctermfg=3
142 highlight GitGutterDelete ctermfg=1
143 highlight GitGutterChangeDelete ctermfg=4
144 hi LspDiagnosticsVirtualTextError guifg=Red ctermfg=Red
145
146
147 " close tag options
148 " filenames like *.xml, *.html, *.xhtml, ...
149 " These are the file extensions where this plugin is enabled.
150 "
151 let g:closetag_filenames = '*.html,*.xhtml,*.phtml,*.js'
152
153 " filenames like *.xml, *.xhtml, ...
154 " This will make the list of non-closing tags self-closing in the specified files.
155 "
156 let g:closetag_xhtml_filenames = '*.xhtml,*.jsx,*.js'
157
158 " filetypes like xml, html, xhtml, ...
159 " These are the file types where this plugin is enabled.
160 "
161 let g:closetag_filetypes = 'html,xhtml,phtml,javascript'
162
163 " filetypes like xml, xhtml, ...
164 " This will make the list of non-closing tags self-closing in the specified files.
165 "
166 let g:closetag_xhtml_filetypes = 'xhtml,jsx'
167
168 " integer value [0|1]
169 " This will make the list of non-closing tags case-sensitive (e.g. `<Link>` will be closed while `<link>` won't.)
170 "
171 let g:closetag_emptyTags_caseSensitive = 1
172 " dict
173 " Disables auto-close if not in a "valid" region (based on filetype)
174 "
175 let g:closetag_regions = {
176 \ 'typescript.tsx': 'jsxRegion,tsxRegion',
177 \ 'javascript.jsx': 'jsxRegion',
178 \ 'typescriptreact': 'jsxRegion,tsxRegion',
179 \ 'javascriptreact': 'jsxRegion',
180 \ }
181
182 " Shortcut for closing tags, default is '>'
183 "
184 let g:closetag_shortcut = '>'
185
186 " Add > at current position without closing the current tag, default is ''
187 let g:closetag_close_shortcut = '<leader>>'
188
189 "runtime macros/matchit.vim
190
191
192 let g:buffet_powerline_separators = 1
193 let g:buffet_separator = '>'
194 let g:buffet_show_index = 1
195
196 nmap <leader>1 <Plug>BuffetSwitch(1)
197 nmap <leader>2 <Plug>BuffetSwitch(2)
198 nmap <leader>3 <Plug>BuffetSwitch(3)
199 nmap <leader>4 <Plug>BuffetSwitch(4)
200 nmap <leader>5 <Plug>BuffetSwitch(5)
201 nmap <leader>6 <Plug>BuffetSwitch(6)
202 nmap <leader>7 <Plug>BuffetSwitch(7)
203 nmap <leader>8 <Plug>BuffetSwitch(8)
204 nmap <leader>9 <Plug>BuffetSwitch(9)
205 nmap <leader>0 <Plug>BuffetSwitch(10)
206
207
208 " Spaceline customizations...
209 let g:spaceline_separate_style = 'curve'
210 let g:spaceline_colorscheme = 'dracula'
211 command! -bang -nargs=* Rg call fzf#vim#grep("rg --column --line-number --no-heading --color=always --smart-case ".shellescape(<q-args>), 1, {'options': '--delimiter : --nth 4..'}, <bang>0)
212
213 set completeopt=menu,menuone,noselect
214
215 lua require("lsp-config")
216
But when I run any command such as find_files, I get a runtime error, as shown in the screenshot below.
I am wondering, what I am missing here. Do I need to configure anything else to get it properly working?
Edit
Performed
PlugUpdate. It did update some plugins. But the Telescope error doesn't go away.Adding the text version of the error:
E5108: Error executing lua ...ig/nvim/plugged/plenary.nvim//lua/plenary/popup/init.lua:408: Failed to switch to window 1007
stack traceback:
[C]: in function 'nvim_set_current_win'
...ig/nvim/plugged/plenary.nvim//lua/plenary/popup/init.lua:408: in function 'create'
...g/nvim/plugged/telescope.nvim//lua/telescope/pickers.lua:308: in function '_create_window'
...g/nvim/plugged/telescope.nvim//lua/telescope/pickers.lua:378: in function 'find'
.../plugged/telescope.nvim//lua/telescope/builtin/files.lua:268: in function 'v'
.../plugged/telescope.nvim//lua/telescope/builtin/files.lua:614: in function 'v'
...m/plugged/telescope.nvim//lua/telescope/builtin/init.lua:508: in function <...m/plugged/telescope.nvim//lua/telescope/builtin/init.lua:479>
...g/nvim/plugged/telescope.nvim//lua/telescope/command.lua:179: in function 'run_command'
...g/nvim/plugged/telescope.nvim//lua/telescope/command.lua:241: in function 'load_command'
[string ":lua"]:1: in main chunk
Press ENTER or type command to continue

:PlugUpdateto confirm all plug-ins are at the latest version? – filbranden Dec 27 '21 at 20:26