You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If a file has brackets and a dash in the name, using find_file will result in Reverse range in character classhere
Applying the same fix as #2345local cwd = vim.fn.expand(vim.fn.escape(opts.cwd or vim.loop.cwd(), "$?*[]")) fixes this issue, though I'm not entirely sure if this breaks any intentional functionality.
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
- WARNING fd: not found. Install [sharkdp/fd](https://github.com/sharkdp/fd) for extended capabilities
Steps to reproduce
mkdir '[will-fail]'
cd '[will-fail]'
nvim inside of the directory
lua require('telescope.builtin').find_files()
error 😢
Expected behavior
Expect to be able to find files inside the directory
Actual behavior
If a file has brackets and a dash in the name, using find_file will result in Reverse range in character class
Minimal config
vim.cmd[[set runtimepath=$VIMRUNTIME]]vim.cmd[[set packpath=/tmp/nvim/site]]localpackage_root='/tmp/nvim/site/pack'localinstall_path=package_root..'/packer/start/packer.nvim'localfunctionload_plugins()
require('packer').startup {
{
'wbthomason/packer.nvim',
{
'nvim-telescope/telescope.nvim',
requires= {
'nvim-lua/plenary.nvim',
{ 'nvim-telescope/telescope-fzf-native.nvim', run='make' },
},
},
-- ADD PLUGINS THAT ARE _NECESSARY_ FOR REPRODUCING THE ISSUE
},
config= {
package_root=package_root,
compile_path=install_path..'/plugin/packer_compiled.lua',
display= { non_interactive=true },
},
}
end_G.load_config=function()
require('telescope').setup()
require('telescope').load_extension('fzf')
-- ADD INIT.LUA SETTINGS THAT ARE _NECESSARY_ FOR REPRODUCING THE ISSUEendifvim.fn.isdirectory(install_path) ==0thenprint("Installing Telescope and dependencies.")
vim.fn.system { 'git', 'clone', '--depth=1', 'https://github.com/wbthomason/packer.nvim', install_path }
endload_plugins()
require('packer').sync()
vim.cmd[[autocmd User PackerComplete ++once echo "Ready!" | lua load_config()]]
The text was updated successfully, but these errors were encountered:
Hey yeah this is a regular occurrence I've been noticing that's been hard to fix due to how widespread our usage of expand. It's very easy to "over-fix" so to speak.
Description
This is likely related to #2345
If a file has brackets and a dash in the name, using find_file will result in
Reverse range in character class
hereApplying the same fix as #2345
local cwd = vim.fn.expand(vim.fn.escape(opts.cwd or vim.loop.cwd(), "$?*[]"))
fixes this issue, though I'm not entirely sure if this breaks any intentional functionality.Neovim version
Operating system and version
WSL Fedora release 38 (Thirty Eight)
Telescope version / branch / rev
telescope 0.1.x
checkhealth telescope
Steps to reproduce
mkdir '[will-fail]'
cd '[will-fail]'
lua require('telescope.builtin').find_files()
Expected behavior
Expect to be able to find files inside the directory
Actual behavior
If a file has brackets and a dash in the name, using find_file will result in
Reverse range in character class
Minimal config
The text was updated successfully, but these errors were encountered: