All Projects → tamton-aquib → staline.nvim

tamton-aquib / staline.nvim

Licence: MIT license
A modern lightweight statusline and bufferline plugin for neovim in lua. Mainly uses unicode symbols for showing info.

Programming Languages

lua
6591 projects

Projects that are alternatives of or similar to staline.nvim

Vim Crystalline
Functions for taking the monotony out of building your own fancy statusline in Vim
Stars: ✭ 264 (+26.32%)
Mutual labels:  statusline
Powerline Extra Symbols
▶️ Extra glyphs for your powerline separators
Stars: ✭ 778 (+272.25%)
Mutual labels:  statusline
Spaceline.vim
vim statusline like spacemacs
Stars: ✭ 216 (+3.35%)
Mutual labels:  statusline
Pureline
A Pure Bash Powerline PS1 Command Prompt
Stars: ✭ 342 (+63.64%)
Mutual labels:  statusline
Vim Vide
Lightest vimrc, while strong enough. 最轻的vim配置,却足够强!
Stars: ✭ 649 (+210.53%)
Mutual labels:  statusline
Vim Tpipeline
Embed your vim statusline in tmux.
Stars: ✭ 92 (-55.98%)
Mutual labels:  statusline
windline.nvim
Animation statusline, floating window statusline. Use lua + luv make some wind
Stars: ✭ 308 (+47.37%)
Mutual labels:  statusline
vim-modusline
🌈 Mode-specific statusline colors
Stars: ✭ 39 (-81.34%)
Mutual labels:  statusline
Nerd Fonts
Iconic font aggregator, collection, & patcher. 3,600+ icons, 50+ patched fonts: Hack, Source Code Pro, more. Glyph collections: Font Awesome, Material Design Icons, Octicons, & more
Stars: ✭ 31,778 (+15104.78%)
Mutual labels:  statusline
Lsp Status.nvim
Utility functions for getting diagnostic status and progress messages from LSP servers, for use in the Neovim statusline
Stars: ✭ 201 (-3.83%)
Mutual labels:  statusline
Hyper Statusline
Status Line Plugin for Hyper
Stars: ✭ 366 (+75.12%)
Mutual labels:  statusline
Lightline.vim
A light and configurable statusline/tabline plugin for Vim
Stars: ✭ 5,886 (+2716.27%)
Mutual labels:  statusline
Powerline
Powerline is a statusline plugin for vim, and provides statuslines and prompts for several other applications, including zsh, bash, tmux, IPython, Awesome and Qtile.
Stars: ✭ 12,989 (+6114.83%)
Mutual labels:  statusline
Vim Wintabs
Modern buffer manager for Vim
Stars: ✭ 268 (+28.23%)
Mutual labels:  statusline
Vim Airline
lean & mean status/tabline for vim that's light as air
Stars: ✭ 15,873 (+7494.74%)
Mutual labels:  statusline
barow
A minimalist statusline for n/vim
Stars: ✭ 31 (-85.17%)
Mutual labels:  statusline
Neoline.vim
Status Line for Neovim focused on beauty and performance ✅
Stars: ✭ 69 (-66.99%)
Mutual labels:  statusline
buftabline.nvim
A low-config, minimalistic buffer tabline Neovim plugin written in Lua.
Stars: ✭ 74 (-64.59%)
Mutual labels:  bufferline
lsp spinner.nvim
neovim plugin to retrieve the name of the running LSP client(s) and display a spinner when there are wip job
Stars: ✭ 23 (-89%)
Mutual labels:  statusline
Lualine.nvim
A blazing fast and easy to configure neovim statusline written in pure lua.
Stars: ✭ 198 (-5.26%)
Mutual labels:  statusline

staline.nvim

TLDR;
staline(statusline): A simple statusline for neovim written in lua.
stabline(s-tabline): A simple bufferline for neovim written in lua. (sry didnt get a better name.)

Requirements

  • Requires neovim version >= 0.7
  • vim.opt.laststatus=2 in your init.lua for statusline. (or 3 for global line)
  • vim.opt.showtabline=2 in your init.lua for bufferline.
  • vim.opt.termguicolors = true must be set.

Installation

use 'tamton-aquib/staline.nvim'

Note Doing this will install both staline and stabline.
But separate setup() is required for each to load up.

Statusline

Screenshots

normal insert command visual

Configuration

require('staline').setup()
Click to see default configuration
require('staline').setup {
    defaults = {
        expand_null_ls = false,  -- This expands out all the null-ls sources to be shown
        left_separator  = "",
        right_separator = "",
        full_path       = false,
        line_column     = "[%l/%L] :%c 並%p%% ", -- `:h stl` to see all flags.

        fg              = "#000000",  -- Foreground text color.
        bg              = "none",     -- Default background is transparent.
        inactive_color  = "#303030",
        inactive_bgcolor = "none",
        true_colors     = false,      -- true lsp colors.
        font_active     = "none",     -- "bold", "italic", "bold,italic", etc

        mod_symbol      = "",
        lsp_client_symbol = "",
        branch_symbol   = "",
        cool_symbol     = "",       -- Change this to override default OS icon.
        null_ls_symbol = "",          -- A symbol to indicate that a source is coming from null-ls
    },
    mode_colors = {
        n = "#2bbb4f",
        i = "#986fec",
        c = "#e27d60",
        v = "#4799eb",   -- etc..
    },
    mode_icons = {
        n = "",
        i = "",
        c = "",
        v = "",   -- etc..
    },
    sections = {
        left = { '- ', '-mode', 'left_sep_double', ' ', 'branch' },
        mid  = { 'file_name' },
        right = { 'cool_symbol','right_sep_double', '-line_column' },
    },
    special_table = {
        NvimTree = { 'NvimTree', '' },
        packer = { 'Packer','' },        -- etc
    },
    lsp_symbols = {
        Error="",
        Info="",
        Warn="",
        Hint="",
    },
}
Sections
section use
mode shows the mode
branch shows git branch
file_name shows filename
file_size shows file size
cool_symbol an icon according to the OS type (cutomizable)
lsp lsp diagnostics (number of errors, warnings, etc)
lsp_name lsp client name
line_column shows line, column, percentage, etc
left_sep single left separator
right_sep single right separator
left_sep_double Double left separator with a shade of gray
right_sep_double Double right separator with a shade of gray
cwd Current working directory

To know more about colors and highlights, check highlights wiki

A section (left, right or mid) can take:

  • Already defnined section or a simple string:
    • "branch"
    • "a simple string"
  • An array of { highlight, string }
    • { "DiagnosticsError", "danger_icon" }
    • { "CustomHighlight", "simple_string" }
  • A function for dynamic content
     function()
         return "computed_dynamic_string"
     end

lsp, lsp_name, file_size sections are not included in the default settings.

Showcase

  • Evil Line evil_line

  • Pebble Line pebble_line

  • Simple Line simple_line

Check out wiki to see some premade configs and tips.

Bufferline

Screenshots

bar mode

slant mode

arrow mode

bubble mode

  • Configuration
     require('stabline').setup()
The Default configuration looks something like
require('stabline').setup {
	style       = "bar", -- others: arrow, slant, bubble
	stab_left   = "",
	stab_right  = " ",

	-- fg          = Default is fg of "Normal".
	-- bg          = Default is bg of "Normal".
	inactive_bg = "#1e2127",
	inactive_fg = "#aaaaaa",
	-- stab_bg     = Default is darker version of bg.,

	font_active = "bold",
	exclude_fts = { 'NvimTree', 'dashboard', 'lir' },
	stab_start  = "",   -- The starting of stabline
	stab_end    = "",
}
My personal config as of editing this file

my stabline config

require('stabline').setup {
	style = "slant",
	bg = "#986fec",
	fg = "black",
	stab_right = "",
}

Features

  • Lightweight and Fast. staline+stabline took < 1ms. (packers profiling)
  • Unicode current mode info. Needs a Nerd Font to be installed.
  • Has few builtin sections to chose from.
  • Uses nvim-web-devicons if installed, else uses a default table.

Cons

  • No mouse functions for stabline.
  • No ordering or sorting functions for stabline.
  • No lsp info in stabline.
  • No git related info on staline except branch name.

Inspiration and credits:

TODO

  • User configuration options. Needs more work.
  • Git info. Only branch info for now, (or ever)
  • Adding "opt-in" bufferline function.
  • Add config options for bufferline.
  • lsp client name in staline.
  • buf numbers in stabline.
  • transparency problem when changed to 0.7 api.
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].