diff options
| author | triethyl <triethylammonium@pm.me> | 2025-08-16 20:20:21 -0400 |
|---|---|---|
| committer | triethyl <triethylammonium@pm.me> | 2025-08-16 20:20:21 -0400 |
| commit | 58ceb817bb6ba195d1189160878f318f3bcda0ef (patch) | |
| tree | 6c17c013c92af8c6e410bb1d4fe3a2557841d0d3 /pkgs/old-custom-neovim/config/lua/plugins/incline.lua | |
| parent | 94980b0be13a690128992d98a2ed5db3ab592642 (diff) | |
neovim: restarted config
Diffstat (limited to 'pkgs/old-custom-neovim/config/lua/plugins/incline.lua')
| -rw-r--r-- | pkgs/old-custom-neovim/config/lua/plugins/incline.lua | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/pkgs/old-custom-neovim/config/lua/plugins/incline.lua b/pkgs/old-custom-neovim/config/lua/plugins/incline.lua new file mode 100644 index 0000000..92ced03 --- /dev/null +++ b/pkgs/old-custom-neovim/config/lua/plugins/incline.lua @@ -0,0 +1,25 @@ +local icons = require 'mini.icons' +require('incline').setup { + hide = { + only_win = true, + }, + window = { + padding = 0, + margin = { horizontal = 0 }, + }, + render = function(props) + local filename = vim.fn.fnamemodify(vim.api.nvim_buf_get_name(props.buf), ':t') + if filename == '' then + filename = '[No Name]' + end + local ft_icon, ft_hl = icons.get("file", filename) + local modified = vim.bo[props.buf].modified + return { + ft_icon and { ' ', ft_icon, ' ', gui = ft_hl } or '', + ' ', + { filename, gui = 'bold' }, + ' ', + modified and '[+] ' or '', + } + end, +} |
