diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt index 4f35ca6c4b..d82ebb71b3 100644 --- a/runtime/doc/options.txt +++ b/runtime/doc/options.txt @@ -2711,7 +2711,7 @@ A jump table for the options with a short description can be found at |Q_op|. illegal byte sequence. WRONG VALUES: WHAT'S WRONG: latin1,utf-8 "latin1" will always be used - utf-8,ucs-bom,latin1 BOM won't be recognized in an utf-8 + utf-8,ucs-bom,latin1 BOM won't be recognized in a utf-8 file cp1250,latin1 "cp1250" will always be used If 'fileencodings' is empty, 'fileencoding' is not modified. diff --git a/runtime/doc/vimfn.txt b/runtime/doc/vimfn.txt index f15bc1deff..60962561e7 100644 --- a/runtime/doc/vimfn.txt +++ b/runtime/doc/vimfn.txt @@ -2136,6 +2136,9 @@ expand({string} [, {nosuf} [, {list}]]) *expand()* :r Root (one extension removed) :e Extension only + More modifiers are supported, for the full list see + |filename-modifiers|. + Example: >vim let &tags = expand("%:p:h") .. "/tags" < Note that when expanding a string that starts with '%', '#' or diff --git a/runtime/lua/vim/_meta/options.lua b/runtime/lua/vim/_meta/options.lua index c9a590f5c7..6323d11d4c 100644 --- a/runtime/lua/vim/_meta/options.lua +++ b/runtime/lua/vim/_meta/options.lua @@ -2413,7 +2413,7 @@ vim.bo.fenc = vim.bo.fileencoding --- illegal byte sequence. --- WRONG VALUES: WHAT'S WRONG: --- latin1,utf-8 "latin1" will always be used ---- utf-8,ucs-bom,latin1 BOM won't be recognized in an utf-8 +--- utf-8,ucs-bom,latin1 BOM won't be recognized in a utf-8 --- file --- cp1250,latin1 "cp1250" will always be used --- If 'fileencodings' is empty, 'fileencoding' is not modified. diff --git a/runtime/lua/vim/_meta/vimfn.lua b/runtime/lua/vim/_meta/vimfn.lua index 436da3ae3f..4302c3d689 100644 --- a/runtime/lua/vim/_meta/vimfn.lua +++ b/runtime/lua/vim/_meta/vimfn.lua @@ -1893,6 +1893,9 @@ function vim.fn.exp(expr) end --- :r Root (one extension removed) --- :e Extension only --- +--- More modifiers are supported, for the full list see +--- |filename-modifiers|. +--- --- Example: >vim --- let &tags = expand("%:p:h") .. "/tags" --- vim let &tags = expand("%:p:h") .. "/tags"