diff options
| author | Lewis Russell <lewis6991@gmail.com> | 2024-09-21 16:23:00 +0100 |
|---|---|---|
| committer | Lewis Russell <me@lewisr.dev> | 2024-09-22 15:05:24 +0100 |
| commit | 511b991e66892b4bb8176ce64c0e8fefb300f638 (patch) | |
| tree | af0524ac4a781c0e719d056502be19983403cb01 /runtime/doc | |
| parent | 29bceb4f758097cc6b66726f1dcd3967ad170e35 (diff) | |
| download | rneovim-511b991e66892b4bb8176ce64c0e8fefb300f638.tar.gz rneovim-511b991e66892b4bb8176ce64c0e8fefb300f638.tar.bz2 rneovim-511b991e66892b4bb8176ce64c0e8fefb300f638.zip | |
feat(fs.lua): add vim.fs.rm()
Analogous to the shell `rm` command.
Diffstat (limited to 'runtime/doc')
| -rw-r--r-- | runtime/doc/lua.txt | 10 | ||||
| -rw-r--r-- | runtime/doc/news.txt | 2 |
2 files changed, 11 insertions, 1 deletions
diff --git a/runtime/doc/lua.txt b/runtime/doc/lua.txt index 1283aac5ca..f3a40cf17a 100644 --- a/runtime/doc/lua.txt +++ b/runtime/doc/lua.txt @@ -3021,6 +3021,16 @@ vim.fs.parents({start}) *vim.fs.parents()* (`nil`) (`string?`) +vim.fs.rm({path}, {opts}) *vim.fs.rm()* + Remove files or directories + + Parameters: ~ + • {path} (`string`) Path to remove + • {opts} (`table?`) A table with the following fields: + • {recursive}? (`boolean`) Remove directories and their + contents recursively + • {force}? (`boolean`) Ignore nonexistent files and arguments + vim.fs.root({source}, {marker}) *vim.fs.root()* Find the first parent directory containing a specific "marker", relative to a file path or buffer. diff --git a/runtime/doc/news.txt b/runtime/doc/news.txt index e0e90f78ec..df86cc9244 100644 --- a/runtime/doc/news.txt +++ b/runtime/doc/news.txt @@ -152,7 +152,7 @@ LSP LUA -• TODO +• |vim.fs.rm()| can delete files and directories. OPTIONS |