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 @@
# Dirs Functions
> you can use Dirs functions to get some directory path
### plugin_dir() -> string
You can get current plugin **root** directory path
```lua
local path = plugin.dirs.plugin_dir()
-- example: ~/Development/DioxusCli/plugin/test-plugin/
```
### bin_dir() -> string
You can get plugin **bin** direcotry path
Sometime you need install some binary file like `tailwind-cli` & `sass-cli` to help your plugin work, then you should put binary file in this directory.
```lua
local path = plugin.dirs.bin_dir()
-- example: ~/Development/DioxusCli/plugin/test-plugin/bin/
```
### temp_dir() -> string
You can get plugin **temp** direcotry path
Just put some temporary file in this directory.
```lua
local path = plugin.dirs.bin_dir()
-- example: ~/Development/DioxusCli/plugin/test-plugin/temp/
```