docs: Update mactag.yazi README.md

This commit is contained in:
sxyazi
2024-10-10 18:35:29 +08:00
parent 35100e7dc1
commit 932b9311a8

View File

@@ -21,7 +21,7 @@ Add the following to your `~/.config/yazi/init.lua`:
```lua
require("mactag"):setup {
-- You can change the colors of the tags here
-- Keys used to add or remove tags
keys = {
r = "Red",
o = "Orange",
@@ -30,6 +30,7 @@ require("mactag"):setup {
b = "Blue",
p = "Purple",
},
-- Colors used to display tags
colors = {
Red = "#ee7b70",
Orange = "#f5bd5c",
@@ -57,16 +58,18 @@ run = "mactag"
## Usage
This plugin also provides the functionality to add and remove tags. Add following keybindings to your `~/.config/yazi/keymap.toml` to enable it:
Besides displaying tags attached to files, you can also add or remove tags within Yazi using this plugin.
Add following keybindings to your `~/.config/yazi/keymap.toml` to enable it:
```toml
[[manager.prepend_keymap]]
on = [ "b", "a" ]
run = 'plugin mactag --args="add"'
desc = "Add tag to selected files"
desc = "Tag selected files"
[[manager.prepend_keymap]]
on = [ "b", "r" ]
run = 'plugin mactag --args="remove"'
desc = "Remove tag from selected files"
desc = "Untag selected files"
```