• This repository has been archived on 18/Aug/2023
  • Stars
    star
    232
  • Rank 172,847 (Top 4 %)
  • Language
    Lua
  • License
    MIT License
  • Created over 3 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A "buffer and tab" tabline for neovim

This plugin is archived. Check out the following instead:


tabline.nvim

A "buffer and tab" tabline:

  • Show buffers and tabs in tabline
  • Use same style as lualine by default
  • Uses same section and component separators as lualine by default
  • Bold buffers that are visible
  • Ability to name tabs
  • Toggle showing buffers per tabs
  • Support nvim-web-devicons
  • Works with sessions

Installation

Using Packer

use {
  'kdheepak/tabline.nvim',
  config = function()
    require'tabline'.setup {
      -- Defaults configuration options
      enable = true,
      options = {
      -- If lualine is installed tabline will use separators configured in lualine by default.
      -- These options can be used to override those settings.
        section_separators = {'๎‚ฐ', '๎‚ฒ'},
        component_separators = {'๎‚ฑ', '๎‚ณ'},
        max_bufferline_percent = 66, -- set to nil by default, and it uses vim.o.columns * 2/3
        show_tabs_always = false, -- this shows tabs only when there are more than one tab or if the first tab is named
        show_devicons = true, -- this shows devicons in buffer section
        show_bufnr = false, -- this appends [bufnr] to buffer section,
        show_filename_only = false, -- shows base filename only instead of relative path in filename
        modified_icon = "+ ", -- change the default modified icon
        modified_italic = false, -- set to true by default; this determines whether the filename turns italic if modified
        show_tabs_only = false, -- this shows only tabs instead of tabs + buffers
      }
    }
    vim.cmd[[
      set guioptions-=e " Use showtabline in gui vim
      set sessionoptions+=tabpages,globals " store tabpages and globals in session
    ]]
  end,
  requires = { { 'hoob3rt/lualine.nvim', opt=true }, {'kyazdani42/nvim-web-devicons', opt = true} }
}

Usage

:TablineBufferNext

Move to next buffer in the tabline.

:TablineBufferPrevious

Move to previous buffer in the tabline.

:TablineTabNew {filename1.ext} {filename2.ext}

Open a new tab with these files.

:TablineToggleShowAllBuffers

Toggles whether to show all buffers that are open versus only buffers that are currently visible or bound.

:TablineBuffersBind {filename1.ext} {filename2.ext}

Bind the current tab's buffers to these files.

:TablineBuffersClearBind

Clear the binding of current tab's buffers.

:TablineTabRename {name}

Rename current tab's name.

Configuration

You can customize the behavior of this extension by setting values for any of the following optional parameters.

tabline_show_devicons

Show devicons in tabline for each buffer (default = true)

tabline_show_bufnr

Show bufnr in tabline for each buffer (default = false)

tabline_show_filename_only

Show only filename instead of shortened full path (default = false)

tabline_show_last_separator

Show separator after the last buffer or tab (default = false)

tabline_show_tabs_only

Show only tabs instead of tabs + buffers (default = false)

Lualine tabline support

nvim-lualine/lualine.nvim now has buffers and tabs as components. If you are not interested in binding buffers to tabs, I'd recommend using those components. They work well in any section.

If you'd still like to use tabline with lualine's tabline instead, you can do the following:

use {
  'kdheepak/tabline.nvim',
  config = function()
    require'tabline'.setup {enable = false}
  end,
  requires = {'hoob3rt/lualine.nvim', 'kyazdani42/nvim-web-devicons'}
}

require'lualine'.setup {
  tabline = {
    lualine_a = {},
    lualine_b = {},
    lualine_c = { require'tabline'.tabline_buffers },
    lualine_x = { require'tabline'.tabline_tabs },
    lualine_y = {},
    lualine_z = {},
  },
}

Currently, this works best when the buffers and tabs are in section lualine_c and lualine_x respectively. Support for other sections will be added in the future.

More Repositories

1

taskwarrior-tui

`taskwarrior-tui`: A terminal user interface for taskwarrior
Rust
1,398
star
2

lazygit.nvim

Plugin for calling lazygit from within neovim.
Lua
1,317
star
3

panvimdoc

Write documentation in pandoc markdown. Generate documentation in vimdoc.
CSS
242
star
4

cmp-latex-symbols

Add latex symbol support for nvim-cmp.
Lua
125
star
5

TerminalUserInterfaces.jl

Terminal User Interfaces in Julia.
Julia
93
star
6

monochrome.nvim

A monochrome colorscheme for neovim
Lua
88
star
7

JuliaFormatter.vim

A (N)Vim plugin for formatting Julia code using JuliaFormatter.jl.
Vim Script
70
star
8

Presentation.jl

Julia
41
star
9

c3.py

Commit Counter Chart is a Python Flask app to view git history using D3.js
HTML
39
star
10

FIGlet.jl

Julia
26
star
11

awesome-advent-of-code

19
star
12

dotfiles

Shell
16
star
13

ReverseStackTraces.jl

Display stack traces in reverse order
Julia
13
star
14

github-release

github-release is a command line utility tool that allows you to easily manage your releases on GitHub.
Nim
13
star
15

nvim-dap-julia

Lua
13
star
16

moonshine.nvim

Rust
12
star
17

keystrokes.nvim

Show keystrokes in neovim.
Lua
11
star
18

PyomoGettingStarted

IPython notebooks that illustrate the Pyomo optimization modeling software
Python
10
star
19

JET.nvim

Julia
10
star
20

pandoc-ieee-template

TeX
9
star
21

psst

Python
9
star
22

pelican-smoothie

Pelican-Smoothie - A Bootstrap theme for the static site generator Pelican
CSS
8
star
23

think-git

A intermediate git tutorial
HTML
7
star
24

PySyntax.jl

(*deprecated*) PySyntax.jl allows Python-like syntax in Julia. Py.jl provides a light wrapper on top of PyCall.jl in the form of a macro.
Jupyter Notebook
6
star
25

TERMIOS.jl

This Julia package provides an TERMIOS interface to the POSIX calls for tty I/O control.
Julia
6
star
26

Pandoc.jl

Pandoc Interface and Types in Julia
Julia
5
star
27

Notcurses.jl

Julia
5
star
28

blog

My personal thoughts and notes
TeX
4
star
29

sveltekit-shiki-endpoint-error

JavaScript
4
star
30

tasker_sl4a

Python Code that parses public Google Calendar feed for events and event location
Python
4
star
31

juliacon2020-terminal-user-interfaces-in-julia

Julia
3
star
32

quarto-svgbob

Render svgbob diagrams directly in your quarto documents.
Lua
3
star
33

mpld3_plugins

Python
3
star
34

ts-julia-actions

Lua
3
star
35

libcrossterm

libcrossterm is a Rust cdylib library providing a C-API to access the excellent crossterm crate.
Rust
3
star
36

pandoc-paper

CSS
3
star
37

Crossterm.jl

Julia
2
star
38

fono

Find number of optimal order from websites considering shipping costs
Python
2
star
39

jupyter-notebook

HTML
2
star
40

kdheepak.github.io

TeX
2
star
41

GeekToolBash

A bash script to download random Calvin and Hobbes comic strips from gocomics.com/calvinandhobbes/
Shell
2
star
42

remark-svgbob

Convert markdown codeblock with ascii diagram to svg using svgbob wasm
JavaScript
2
star
43

juliacon2019-open-source-power-system-production-cost-modeling-in-julia

Jupyter Notebook
2
star
44

Tasker_WhatsPush

Forward Whatsapp Messages to and Reply from Desktop
1
star
45

pandasplexos

Python
1
star
46

mwe-swig-python3-anaconda

C
1
star
47

game-of-life

Rust
1
star
48

juliacon2019-why-writing-c-interfaces-in-julia-is-so-easy-asterisk

Julia
1
star
49

adventofcode

Julia
1
star
50

iou

Solve for the optimally minimum number of transactions to settle debts and expenses with friends
Python
1
star
51

pandoc-ipynb

HTML
1
star
52

opendss-mirror

Pascal
1
star
53

interactive-data-visualizations-with-bokeh

Interactive Data Visualizations with Bokeh
JavaScript
1
star
54

license

`license` is a command line utility tool that allows you to easily add licenses to your open source projects
Nim
1
star
55

mergetool.nvim

1
star
56

d2-markdown-preview

d2 vscode markdown preview extension
TypeScript
1
star
57

nvim

Lua
1
star