Skip to content

Commit 4054421

Browse files
committed
feat(#2127): normalise relative_path in config hierarchy
1 parent 9ae5afd commit 4054421

File tree

3 files changed

+11
-7
lines changed

3 files changed

+11
-7
lines changed

doc/nvim-tree-lua.txt

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -621,8 +621,10 @@ Following is the default configuration. See |nvim-tree-opts| for details.
621621
},
622622
},
623623
experimental = {
624-
open = {
625-
relative_path = false,
624+
actions = {
625+
open_file = {
626+
relative_path = false,
627+
},
626628
},
627629
},
628630
log = {
@@ -1540,7 +1542,7 @@ Confirmation prompts.
15401542
Experimental features that may become default or optional functionality.
15411543
In the event of a problem please disable the experiment and raise an issue.
15421544

1543-
*nvim-tree.open.relative_path*
1545+
*nvim-tree.actions.open_file.relative_path*
15441546
Buffers opened by nvim-tree will use with relative paths instead of
15451547
absolute.
15461548
Execute |:ls| to see the paths of all open buffers.
@@ -2762,6 +2764,7 @@ highlight group is not, hard linking as follows: >
27622764
|nvim-tree.actions.open_file|
27632765
|nvim-tree.actions.open_file.eject|
27642766
|nvim-tree.actions.open_file.quit_on_open|
2767+
|nvim-tree.actions.open_file.relative_path|
27652768
|nvim-tree.actions.open_file.resize_window|
27662769
|nvim-tree.actions.open_file.window_picker|
27672770
|nvim-tree.actions.open_file.window_picker.chars|
@@ -2822,7 +2825,6 @@ highlight group is not, hard linking as follows: >
28222825
|nvim-tree.modified.show_on_open_dirs|
28232826
|nvim-tree.notify.threshold|
28242827
|nvim-tree.on_attach|
2825-
|nvim-tree.open.relative_path|
28262828
|nvim-tree.prefer_startup_root|
28272829
|nvim-tree.reload_on_bufenter|
28282830
|nvim-tree.renderer.add_trailing|

lua/nvim-tree.lua

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -585,8 +585,10 @@ local DEFAULT_OPTS = { -- BEGIN_DEFAULT_OPTS
585585
},
586586
},
587587
experimental = {
588-
open = {
589-
relative_path = false,
588+
actions = {
589+
open_file = {
590+
relative_path = false,
591+
},
590592
},
591593
},
592594
log = {

lua/nvim-tree/actions/node/open-file.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -419,7 +419,7 @@ end
419419
function M.setup(opts)
420420
M.quit_on_open = opts.actions.open_file.quit_on_open
421421
M.resize_window = opts.actions.open_file.resize_window
422-
M.relative_path = opts.experimental.open.relative_path
422+
M.relative_path = opts.experimental.actions.open_file.relative_path
423423
if opts.actions.open_file.window_picker.chars then
424424
opts.actions.open_file.window_picker.chars = tostring(opts.actions.open_file.window_picker.chars):upper()
425425
end

0 commit comments

Comments
 (0)