neo-tree.nvim icon indicating copy to clipboard operation
neo-tree.nvim copied to clipboard

[Feature Request] File nesting for filename patterns

Open akinsho opened this issue 2 years ago • 2 comments

In some languages, for example in go identifying a test or other related file might use a different filename pattern e.g. a go file ends with file.go and its test will end with file_test.go I believe this is also a pattern used in several other languages e.g. _spec.blah etc. I see from the original issue/PR that the decision was to go with the simplest solution, however I think there are a bunch of use cases in other languages that would be served by allowing nesting based on filename patterns.

Any thoughts on having file nesting work for these use cases as well?

akinsho avatar May 06 '22 10:05 akinsho

Yes, I realize that this should be revised to handle more use cases. There is also another issue to enhance this functionality: #334

I had not thought about nesting the _test / _spec files before but it is certainly a good point. I'm not personally a big user of the nesting feature so it's not high on my list of todos. I only want to nest compiled files like .ts --> .js.

cseickel avatar May 06 '22 11:05 cseickel

I've got an another face to this issue, I couldn't nest the file pattern below as

js = { 'js.map', 'd.ts' }

image

RaafatTurki avatar Aug 16 '22 00:08 RaafatTurki

I just want to add another example:

["package.json"] = { "package-lock.json", "yarn.lock" }

which would nest package-lock.json and yarn.lock below/inside a package.json ;-)

Teddytrombone avatar Oct 12 '23 07:10 Teddytrombone