aboutsummaryrefslogtreecommitdiff
path: root/runtime/doc
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/doc')
-rw-r--r--runtime/doc/lua.txt14
-rw-r--r--runtime/doc/news.txt1
2 files changed, 15 insertions, 0 deletions
diff --git a/runtime/doc/lua.txt b/runtime/doc/lua.txt
index 711607d14b..a2a83ef229 100644
--- a/runtime/doc/lua.txt
+++ b/runtime/doc/lua.txt
@@ -2945,6 +2945,20 @@ Example: >lua
<
+vim.fs.abspath({path}) *vim.fs.abspath()*
+ Convert path to an absolute path. A tilde (~) character at the beginning
+ of the path is expanded to the user's home directory. Does not check if
+ the path exists, normalize the path, resolve symlinks or hardlinks
+ (including `.` and `..`), or expand environment variables. If the path is
+ already absolute, it is returned unchanged. Also converts `\` path
+ separators to `/`.
+
+ Parameters: ~
+ • {path} (`string`) Path
+
+ Return: ~
+ (`string`) Absolute path
+
vim.fs.basename({file}) *vim.fs.basename()*
Return the basename of the given path
diff --git a/runtime/doc/news.txt b/runtime/doc/news.txt
index c4ba4f0ad1..7ea65479f3 100644
--- a/runtime/doc/news.txt
+++ b/runtime/doc/news.txt
@@ -268,6 +268,7 @@ LUA
is more performant and easier to read.
• |vim.str_byteindex()| and |vim.str_utfindex()| gained overload signatures
supporting two new parameters, `encoding` and `strict_indexing`.
+• |vim.fs.abspath()| converts paths to absolute paths.
OPTIONS