Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ldelossa/buffertag
https://github.com/ldelossa/buffertag
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/ldelossa/buffertag
- Owner: ldelossa
- License: mit
- Created: 2022-07-16T22:56:49.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2023-01-17T14:47:20.000Z (over 1 year ago)
- Last Synced: 2024-06-17T19:58:52.216Z (3 months ago)
- Language: Lua
- Size: 262 KB
- Stars: 47
- Watchers: 1
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# Buffertag
![buffertag screenshot](./docs/shadow-border.png)
Buffertag is a very simple plugin which always shows the buffer name in non-focused
windows.This is designed to be used with the `set laststatus=3` configuration which removes
the unnecessary status lines on each window.This idea came from enjoying the space saving of `set laststatus=3` but missing
the ability to quickly reference which buffers are in which windows. I split
hard, and I split often.# Usage
## Include in Vim Plug (or your package manager of choice)
```vim
Plug 'ldelossa/buffertag'
```## Call setup with an optional config
```lua
lua require('buffertag').setup({
-- accepts any border options that `nvim_open_win` accepts.
-- see ":help vim.api.nvim_open_win"
border = "none",
-- By default if the buffer name is too wide for the pane it's in, it will
-- display and overlap the pane. By setting this to true, the buffer name will
-- be truncated to fit within the pane, ensuring the floating window does not
-- overlap any other panes.
limit_width = false,
-- if `vim.bo.modified` is `true` for the current buffer,
-- display modified symbol before the buffer name.
modified_symbol = "[+]", -- other modified symbol: "●"
})
```## Toggle it on and off
```
: BuffertagToggle
```# Demo
Checkout the demo video [here](https://youtu.be/NhhsLYnYjRU)