All Projects β†’ ojroques β†’ nvim-hardline

ojroques / nvim-hardline

Licence: BSD-2-Clause license
A simple Neovim statusline

Programming Languages

lua
6591 projects
Vim Script
2826 projects

Projects that are alternatives of or similar to nvim-hardline

Lualine.nvim
A blazing fast and easy to configure neovim statusline written in pure lua.
Stars: ✭ 198 (+62.3%)
Mutual labels:  statusline, neovim-plugin
trouble.nvim
🚦 A pretty diagnostics, references, telescope results, quickfix and location list to help you solve all the trouble your code is causing.
Stars: ✭ 2,663 (+2082.79%)
Mutual labels:  neovim-plugin, neovim-lua
Lsp Status.nvim
Utility functions for getting diagnostic status and progress messages from LSP servers, for use in the Neovim statusline
Stars: ✭ 201 (+64.75%)
Mutual labels:  statusline, neovim-plugin
package-info.nvim
✍️ All the npm/yarn commands I don't want to type
Stars: ✭ 248 (+103.28%)
Mutual labels:  neovim-plugin, neovim-lua
diffview.nvim
Single tabpage interface for easily cycling through diffs for all modified files for any git rev.
Stars: ✭ 1,472 (+1106.56%)
Mutual labels:  neovim-plugin, neovim-lua
neogen
A better annotation generator. Supports multiple languages and annotation conventions.
Stars: ✭ 339 (+177.87%)
Mutual labels:  neovim-plugin, neovim-lua
modes.nvim
Prismatic line decorations for the adventurous vim user
Stars: ✭ 299 (+145.08%)
Mutual labels:  neovim-plugin, neovim-lua
Comment.nvim
🧠 πŸ’ͺ // Smart and powerful comment plugin for neovim. Supports treesitter, dot repeat, left-right/up-down motions, hooks, and more
Stars: ✭ 796 (+552.46%)
Mutual labels:  neovim-plugin, neovim-lua
which-key.nvim
πŸ’₯ Create key bindings that stick. WhichKey is a lua plugin for Neovim 0.5 that displays a popup with possible keybindings of the command you started typing.
Stars: ✭ 2,043 (+1574.59%)
Mutual labels:  neovim-plugin, neovim-lua
awesome-neovim
Awesome Configurations for C/C++,Zig,Web and Lua development in NeoVim
Stars: ✭ 54 (-55.74%)
Mutual labels:  neovim-plugin, neovim-lua
tmux.nvim
tmux integration for nvim features pane movement and resizing from within nvim.
Stars: ✭ 299 (+145.08%)
Mutual labels:  neovim-plugin, neovim-lua
winshift.nvim
Rearrange your windows with ease.
Stars: ✭ 230 (+88.52%)
Mutual labels:  neovim-plugin, neovim-lua
feline.nvim
A minimal, stylish and customizable statusline for Neovim written in Lua
Stars: ✭ 867 (+610.66%)
Mutual labels:  statusline, neovim-plugin
github-notifications.nvim
Statusline + Telescope integration for viewing and interacting with GitHub notifications
Stars: ✭ 70 (-42.62%)
Mutual labels:  statusline, neovim-plugin
telescope-repo.nvim
🦘 Jump into the repositories (git, mercurial…) of your filesystem with telescope.nvim, without any setup
Stars: ✭ 99 (-18.85%)
Mutual labels:  neovim-lua
vim-dap
Vim/Neovim debugger plugin providing a terminal interface to the Debug Adapter Protocol
Stars: ✭ 43 (-64.75%)
Mutual labels:  neovim-plugin
fzf-checkout.vim
Manage branches and tags with fzf
Stars: ✭ 187 (+53.28%)
Mutual labels:  neovim-plugin
cutlass.nvim
Plugin that adds a 'cut' operation separate from 'delete'
Stars: ✭ 78 (-36.07%)
Mutual labels:  neovim-plugin
cmp-rg
ripgrep source for nvim-cmp
Stars: ✭ 165 (+35.25%)
Mutual labels:  neovim-plugin
snippets.nvim
No description or website provided.
Stars: ✭ 30 (-75.41%)
Mutual labels:  neovim-plugin

nvim-hardline

A statusline / bufferline for Neovim written in Lua. It is inspired by vim-airline but aims to be as light and simple as possible.

Note: I won't add new features/parts/themes if I don't need them. Feel free to submit PRs or fork the plugin though.

screenshot

Installation

With packer.nvim:

use {'ojroques/nvim-hardline'}

With paq-nvim:

paq {'ojroques/nvim-hardline'}

Usage

In your init.lua:

require('hardline').setup {}

If you're using a .vimrc or init.vim:

lua require('hardline').setup {}

Configuration

You can pass options to the setup() function. Here are all available options with their default settings:

require('hardline').setup {
  bufferline = false,  -- enable bufferline
  bufferline_settings = {
    exclude_terminal = false,  -- don't show terminal buffers in bufferline
    show_index = false,        -- show buffer indexes (not the actual buffer numbers) in bufferline
  },
  theme = 'default',   -- change theme
  sections = {         -- define sections
    {class = 'mode', item = require('hardline.parts.mode').get_item},
    {class = 'high', item = require('hardline.parts.git').get_item, hide = 100},
    {class = 'med', item = require('hardline.parts.filename').get_item},
    '%<',
    {class = 'med', item = '%='},
    {class = 'low', item = require('hardline.parts.wordcount').get_item, hide = 100},
    {class = 'error', item = require('hardline.parts.lsp').get_error},
    {class = 'warning', item = require('hardline.parts.lsp').get_warning},
    {class = 'warning', item = require('hardline.parts.whitespace').get_item},
    {class = 'high', item = require('hardline.parts.filetype').get_item, hide = 60},
    {class = 'mode', item = require('hardline.parts.line').get_item},
  },
}

You can define your own sections using the sections list. Each element of that list is a table with the following attributes:

  • class: the section colorscheme. The following classes are currently available:
    • mode: change color based on the current mode.
    • low, med, high: colors for different levels of importance.
    • bufferline: colors for the bufferline.
    • error, warning: colors for the diagnostics of Neovim built-in LSP client.
  • item: the actual text being displayed. Must be a string or a function returning a string.
  • hide: threshold (in number of characters) below which the section will be hidden.

Available section parts

Part Description
cwd Current working directory
filename Filename and file status (readonly, modified, ...)
filetype Filetype
git Git hunks (requires vim-gitgutter / vim-signify / gitsigns.nvim) and Git branch (requires vim-fugitive / gina.vim / vim-branchname / gitsigns.nvim)
line Line and column positions
lsp Diagnostics from Neovim LSP client
mode Current mode
treesitter-context Current treesitter node (requires nvim-gps)
whitespace Trailing whitespaces, mixed indent and Git conflict markers warnings
wordcount Current word count (enabled only for some filetypes)

License

LICENSE

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].