-
Notifications
You must be signed in to change notification settings - Fork 268
Closed
Labels
bugSomething isn't workingSomething isn't working
Description
Did you check docs and existing issues?
- I have read all the docs.
- I have searched the existing issues.
- I have searched the existing discussions.
Neovim Version (nvim -v)
NVIM v0.10.4
Operating System / Version
Fedora 41
Describe the Bug
If you copy a/
to a/b/
, Neotree correctly refuses the command. However, if you copy a/
to a/b/c/
, Neotree attempts to comply, resulting in recursion that ends in a filesystem error and a deeply nested file tree.
Related: #795
Screenshots, Traceback

Steps to Reproduce
- Create a directory.
- With the cursor over the directory in neotree, press
c
for copy. - In the resulting popup, enter
b/c
Alternatively:
- Create a directory
a/
with a subdirectorya/b/
. - With the cursor over
a/
, pressy
for yank. - With the cursor over
a/b/
, pressp
for paste.
Expected Behavior
Neotree refuses to copy a directory into itself or any descendants.
Your Configuration
vim.env.LAZY_STDPATH = ".repro"
load(vim.fn.system("curl -s https://raw.githubusercontent.com/folke/lazy.nvim/main/bootstrap.lua"))()
require("lazy.minit").repro({
spec = {
{
"nvim-neo-tree/neo-tree.nvim",
branch = "v3.x",
dependencies = {
"nvim-lua/plenary.nvim",
"nvim-tree/nvim-web-devicons",
"MunifTanjim/nui.nvim",
},
lazy = false,
opts = {},
}
},
})
vim.g.mapleader = " "
vim.keymap.set("n", "<leader>e", "<Cmd>Neotree<CR>")
bew
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working