-
Notifications
You must be signed in to change notification settings - Fork 7
Home
imsi32 edited this page Jul 6, 2024
·
3 revisions
Yatline is a plugin for Yazi, a terminal file manager. It customize both header-line and status-line according to your config.
- Yazi: https://github.com/sxyazi/yazi
- Nerd Fonts (optional): https://www.nerdfonts.com/
- Download the repository.
- If the directory is downloaded as zip file, extract it.
- Rename the directory as
yatline.yazi
- Open the config directory of Yazi.
- Copy this directory into
plugins
directory. - Create
init.lua
file in the main Yazi config directory. - Open this file and copy one of the configs to that file.
git clone https://github.com/imsi32/yatline.yazi.git ~/.config/yazi/plugins/yatline.yazi
require("yatline"):setup({
section_separator = { open = "", close = "" },
part_separator = { open = "", close = "" },
style_a = {
fg = "black",
bg_mode = {
normal = "#a89984",
select = "#d79921",
un_set = "#d65d0e"
}
},
style_b = { bg = "#665c54", fg = "#ebdbb2" },
style_c = { bg = "#3c3836", fg = "#a89984" },
permissions_t_fg = "green",
permissions_r_fg = "yellow",
permissions_w_fg = "red",
permissions_x_fg = "cyan",
permissions_s_fg = "darkgray",
tab_width = 20,
selected = { icon = "", fg = "yellow" },
copied = { icon = "", fg = "green" },
cut = { icon = "", fg = "red" },
total = { icon = "", fg = "yellow" },
succ = { icon = "", fg = "green" },
fail = { icon = "", fg = "red" },
found = { icon = "", fg = "blue" },
processed = { icon = "", fg = "green" },
header_line = {
left = {
section_a = {
{type = "line", custom = false, name = "tabs", params = {"left"}},
},
section_b = {
},
section_c = {
}
},
right = {
section_a = {
{type = "string", custom = false, name = "date", params = {"%A, %d %B %Y"}},
},
section_b = {
{type = "string", custom = false, name = "date", params = {"%X"}},
},
section_c = {
}
}
},
status_line = {
left = {
section_a = {
{type = "string", custom = false, name = "tab_mode"},
},
section_b = {
{type = "string", custom = false, name = "hovered_size"},
},
section_c = {
{type = "string", custom = false, name = "hovered_name"},
{type = "coloreds", custom = false, name = "count"},
}
},
right = {
section_a = {
{type = "string", custom = false, name = "cursor_position"},
},
section_b = {
{type = "string", custom = false, name = "cursor_percentage"},
},
section_c = {
{type = "string", custom = false, name = "hovered_file_extension", params = {true}},
{type = "coloreds", custom = false, name = "permissions"},
}
}
},
})
require("yatline"):setup({
section_separator = { open = "", close = "" },
part_separator = { open = "", close = "" },
style_a = {
fg = "black",
bg_mode = {
normal = "#a89984",
select = "#d79921",
un_set = "#d65d0e"
}
},
style_b = { bg = "#665c54", fg = "#ebdbb2" },
style_c = { bg = "#3c3836", fg = "#a89984" },
permissions_t_fg = "green",
permissions_r_fg = "yellow",
permissions_w_fg = "red",
permissions_x_fg = "cyan",
permissions_s_fg = "darkgray",
tab_width = 20,
selected = { icon = "", fg = "yellow" },
copied = { icon = "", fg = "green" },
cut = { icon = "", fg = "red" },
total = { icon = "", fg = "yellow" },
succ = { icon = "", fg = "green" },
fail = { icon = "", fg = "red" },
found = { icon = "", fg = "blue" },
processed = { icon = "", fg = "green" },
header_line = {
left = {
section_a = {
{type = "line", custom = false, name = "tabs", params = {"left"}},
},
section_b = {
},
section_c = {
}
},
right = {
section_a = {
},
section_b = {
{type = "coloreds", custom = true, name = {{" ", "#3c3836"}}},
},
section_c = {
{type = "coloreds", custom = false, name = "count"},
}
}
},
status_line = {
left = {
section_a = {
},
section_b = {
},
section_c = {
}
},
right = {
section_a = {
},
section_b = {
},
section_c = {
}
}
},
})
require("yatline"):setup({
section_separator = { open = "", close = "" },
part_separator = { open = "", close = "" },
style_a = {
fg = "black",
bg_mode = {
normal = "#a89984",
select = "#d79921",
un_set = "#d65d0e"
}
},
style_b = { bg = "#665c54", fg = "#ebdbb2" },
style_c = { bg = "#3c3836", fg = "#a89984" },
permissions_t_fg = "green",
permissions_r_fg = "yellow",
permissions_w_fg = "red",
permissions_x_fg = "cyan",
permissions_s_fg = "darkgray",
tab_width = 20,
selected = { icon = "", fg = "yellow" },
copied = { icon = "", fg = "green" },
cut = { icon = "", fg = "red" },
total = { icon = "", fg = "yellow" },
succ = { icon = "", fg = "green" },
fail = { icon = "", fg = "red" },
found = { icon = "", fg = "blue" },
processed = { icon = "", fg = "green" },
header_line = {
left = {
section_a = {
},
section_b = {
},
section_c = {
}
},
right = {
section_a = {
},
section_b = {
},
section_c = {
}
}
},
status_line = {
left = {
section_a = {
{type = "string", custom = false, name = "tab_mode"},
},
section_b = {
{type = "string", custom = false, name = "hovered_size"},
},
section_c = {
{type = "string", custom = false, name = "hovered_name"},
}
},
right = {
section_a = {
{type = "string", custom = false, name = "cursor_position"},
},
section_b = {
{type = "string", custom = false, name = "cursor_percentage"},
},
section_c = {
{type = "coloreds", custom = false, name = "permissions"},
}
}
},
})