Prepare CLI for move into mainline

This commit is contained in:
Jonathan Kelley committed 2023-06-28 17:21:23 -07:00
1 parent 737910f8ae
commit a9d7b4d32a
83 files changed

No files matched your search

@@ -0,0 +1,35 @@
# Path Functions
> you can use path functions to operate valid path string
### join(path: string, extra: string) -> string
This function can help you extend a path, you can extend any path, dirname or filename.
```lua
local current_path = "~/hello/dioxus"
local new_path = plugin.path.join(current_path, "world")
-- new_path = "~/hello/dioxus/world"
```
### parent(path: string) -> string
This function will return `path` parent-path string, back to the parent.
```lua
local current_path = "~/hello/dioxus"
local new_path = plugin.path.parent(current_path)
-- new_path = "~/hello/"
```
### exists(path: string) -> boolean
This function can check some path (dir & file) is exists.
### is_file(path: string) -> boolean
This function can check some path is a exist file.
### is_dir(path: string) -> boolean
This function can check some path is a exist dir.