diff options
Diffstat (limited to 'runtime/doc')
-rw-r--r-- | runtime/doc/builtin.txt | 15 | ||||
-rw-r--r-- | runtime/doc/usr_41.txt | 1 |
2 files changed, 16 insertions, 0 deletions
diff --git a/runtime/doc/builtin.txt b/runtime/doc/builtin.txt index 97baed6cc9..4bd8975583 100644 --- a/runtime/doc/builtin.txt +++ b/runtime/doc/builtin.txt @@ -3868,6 +3868,21 @@ invert({expr}) *invert()* let bits = invert(bits) < +isabsolutepath({path}) *isabsolutepath()* + The result is a Number, which is |TRUE| when {path} is an + absolute path. + On Unix, a path is considered absolute when it starts with '/'. + On MS-Windows, it is considered absolute when it starts with an + optional drive prefix and is followed by a '\' or '/'. UNC paths + are always absolute. + Example: >vim + echo isabsolutepath('/usr/share/') " 1 + echo isabsolutepath('./foobar') " 0 + echo isabsolutepath('C:\Windows') " 1 + echo isabsolutepath('foobar') " 0 + echo isabsolutepath('\\remote\file') " 1 +< + isdirectory({directory}) *isdirectory()* The result is a Number, which is |TRUE| when a directory with the name {directory} exists. If {directory} doesn't diff --git a/runtime/doc/usr_41.txt b/runtime/doc/usr_41.txt index b3911dfd09..08ef9ac886 100644 --- a/runtime/doc/usr_41.txt +++ b/runtime/doc/usr_41.txt @@ -836,6 +836,7 @@ System functions and manipulation of files: getfperm() get the permissions of a file setfperm() set the permissions of a file getftype() get the kind of a file + isabsolutepath() check if a path is absolute isdirectory() check if a directory exists getfsize() get the size of a file getcwd() get the current working directory |