mirror of
https://github.com/NotAShelf/nvf.git
synced 2025-04-13 16:18:36 +00:00
utility/snacks-nvim: add lualine, bufferline extension / offset
This commit is contained in:
parent
67d9aa7cb5
commit
28af5c1ff9
3 changed files with 30 additions and 27 deletions
|
@ -298,12 +298,12 @@
|
|||
- Add lint (luacheck) and formatting (stylua) support for Lua.
|
||||
- Add lint (markdownlint-cli2) support for Markdown.
|
||||
- Add catppuccin integration for Bufferline, Lspsaga.
|
||||
- Add neo-tree integration for Bufferline.
|
||||
- Add `neo-tree`, `snacks.explorer` integrations to `bufferline`.
|
||||
- Add more applicable filetypes to illuminate denylist.
|
||||
- Disable mini.indentscope for applicable filetypes.
|
||||
- Fix fzf-lua having a hard dependency on fzf.
|
||||
- Enable inlay hints support - `config.vim.lsp.inlayHints`.
|
||||
- Add `neo-tree` extension to `lualine`.
|
||||
- Add `neo-tree`, `snacks.picker` extensions to `lualine`.
|
||||
|
||||
[tebuevd](https://github.com/tebuevd):
|
||||
|
||||
|
|
|
@ -14,17 +14,28 @@
|
|||
bCfg = config.vim.ui.breadcrumbs;
|
||||
in {
|
||||
config = mkMerge [
|
||||
(mkIf config.vim.filetree.nvimTree.enable {
|
||||
vim.statusline.lualine.setupOpts = {
|
||||
extensions = ["nvim-tree"];
|
||||
};
|
||||
})
|
||||
|
||||
(mkIf config.vim.filetree.neo-tree.enable {
|
||||
vim.statusline.lualine.setupOpts = {
|
||||
extensions = ["neo-tree"];
|
||||
};
|
||||
})
|
||||
{
|
||||
vim.statusline.lualine.setupOpts.extensions =
|
||||
(lib.optionals config.vim.filetree.nvimTree.enable ["nvim-tree"])
|
||||
++ (lib.optionals config.vim.filetree.neo-tree.enable ["neo-tree"])
|
||||
++ (lib.optionals config.vim.utility.snacks-nvim.enable [
|
||||
{
|
||||
# same extensions as nerdtree / neo-tree
|
||||
# https://github.com/nvim-lualine/lualine.nvim/blob/master/lua/lualine/extensions/nerdtree.lua
|
||||
# https://github.com/nvim-lualine/lualine.nvim/blob/master/lua/lualine/extensions/neo-tree.lua
|
||||
sections = {
|
||||
lualine_a = mkLuaInline ''
|
||||
{
|
||||
function()
|
||||
return vim.fn.fnamemodify(vim.fn.getcwd(), ":~")
|
||||
end,
|
||||
}
|
||||
'';
|
||||
};
|
||||
filetypes = ["snacks_picker_list" "snacks_picker_input"];
|
||||
}
|
||||
]);
|
||||
}
|
||||
|
||||
(mkIf (bCfg.enable && bCfg.lualine.winbar.enable && bCfg.source == "nvim-navic") {
|
||||
vim.statusline.lualine.setupOpts = {
|
||||
|
|
|
@ -272,20 +272,12 @@ in {
|
|||
|
||||
offsets = mkOption {
|
||||
type = listOf attrs;
|
||||
default = [
|
||||
{
|
||||
filetype = "NvimTree";
|
||||
text = "File Explorer";
|
||||
highlight = "Directory";
|
||||
separator = true;
|
||||
}
|
||||
{
|
||||
filetype = "neo-tree";
|
||||
text = "File Explorer";
|
||||
highlight = "Directory";
|
||||
separator = true;
|
||||
}
|
||||
];
|
||||
default = map (filetype: {
|
||||
inherit filetype;
|
||||
text = "File Explorer";
|
||||
highlight = "Directory";
|
||||
separator = true;
|
||||
}) ["NvimTree" "neo-tree" "snacks_layout_box"];
|
||||
description = "The windows to offset bufferline above, see `:help bufferline-offset`";
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue