Coder Social home page Coder Social logo

tabline.nvim's People

Contributors

bellini666 avatar mg979 avatar rockyzhang24 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

tabline.nvim's Issues

Error when opening a new tab

After latest changes I'm seeing this when trying to open a new tab

E5108: Error executing lua ...packer/start/tabline.nvim/lua/tabline/render/bufline.lua:171: attempt to concatenate upvalue 'iconspacing' (a nil value)                                                                              
stack traceback:
        ...packer/start/tabline.nvim/lua/tabline/render/bufline.lua:171: in function 'buf_icon'
        ...packer/start/tabline.nvim/lua/tabline/render/tabline.lua:147: in function 'tab_icon'
        ...packer/start/tabline.nvim/lua/tabline/render/tabline.lua:166: in function 'format_tab_label'
        ...packer/start/tabline.nvim/lua/tabline/render/tabline.lua:43: in function 'render_tabs'
        ...e/pack/packer/start/tabline.nvim/lua/tabline/tabline.lua:42: in function <...e/pack/packer/start/tabline.nvim/lua/tabline/tabline.lua:38>

Manually adding this line here (https://github.com/mg979/tabline.nvim/blob/master/lua/tabline/render/bufline.lua#L165) fixes the issue:

  local iconspacing = s.icon_spacing or '  '

Best tabline plugin ever

Coming here from vim-xtabline that I have been using for three years. After trying all the tabline/bufferline plugins, unequivocally I can say vim-xtabline (and tabline.nvim) is the best. Definitely! It has all the features a tabline should have. Simple but powerful.

I just want to say thanks here. Thank you for your continued active maintenance ♥️

Stack overflow on setup

When executing

lua require'tabline.setup'.setup()

the following error happens:

E5108: Error executing lua stack overflow
stack traceback:
        [C]: in function 'require'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:150: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:159: in function 'load_theme'
        ...local/share/nvim/lazy/tabline.nvim/lua/tabline/setup.lua:193: in function 'setup'
        [string ":lua"]:1: in main chunk

Indeed the logic in M.load_theme seems buggy, it will be an infinite recursion if the following line fails:

      loaded, theme = pcall(require, 'tabline.themes.' .. M.settings.theme)

Cant use vim-plug to clone tabline repository

I use vim-plug to install my plugins. I am running dozens of plugins all installed by vim-plug. I can install any new plugins as well without any problems. But I get this errors with both mg979/tabline and mg979/vim-xtabtine when trying to install with vim-plug.

A few plugins from my nvim config:

Plug 'ap/vim-buftabline'                                " Minimal buffer status bar
"Plug 'mg979/vim-xtabtine'                          " Full control and customization on tabs/buffers
Plug 'mg979/tabline'                                      " Full control and customization on tabs/buffers
Plug 'skielbasa/vim-material-monokai'       " Theme

Error when using PluginInstall:

- Finishing ... Done!
- delimitMate: Already installed
- fzf: Already installed
- vimwiki: Already installed
- vim-polyglot: Already installed
- colorizer: Already installed
- vim-liquid: Already installed
- fzf.vim: Already installed
- vim-crystal: Already installed
- coc.nvim: Already installed
- vim-rails: Already installed
- vim-repeat: Already installed
- wal.vim: Already installed
- vim-devicons: Already installed
- vim-elixir: Already installed
- vim-buftabline: Already installed
- vim-mix-format: Already installed
- nerdtree: Already installed
- vim-fugitive: Already installed
- vim-material-monokai: Already installed
- vim-airline-themes: Already installed
- vim-surround: Already installed
- vim-slang: Already installed
x tabline:
    Cloning into '/home/narayana/.local/share/nvim/plugged/tabline'...
    ERROR: Repository not found.
    fatal: Could not read from remote repository.
    
    Please make sure you have the correct access rights
    and the repository exists.
- vim-closetag: Already installed
- nerdcommenter: Already installed
- vim-airline: Already installed
- vCoolor.vim: Already installed

vim-fugitive git commands work fine in terminal, I can push to a remote repository.

Cloning int the terminal works fine:

narayana in /tmp λ git clone [email protected]:mg979/tabline.nvim.git
Cloning into 'tabline.nvim'...
remote: Enumerating objects: 1139, done.
remote: Counting objects: 100% (184/184), done.
remote: Compressing objects: 100% (88/88), done.
remote: Total 1139 (delta 90), reused 144 (delta 63), pack-reused 955
Receiving objects: 100% (1139/1139), 178.59 KiB | 758.00 KiB/s, done.
Resolving deltas: 100% (584/584), done.

I have my git email and username set correctly in my ~/.gitconfig file, and have set my git config to use ssh clone over https clone.
Git config:

narayana in ~ λ cat ~/.gitconfig 
[user]
	email = <private>
	name = Narayana108
[init]
	defaultBranch = master
[url "[email protected]:"]
	insteadOf = https://github.com/

Add more themes

Hey,

Would be awesome if more themes could be added here. Maybe start with the most popular ones?

I would vote for jellybeans :)

Customized mapping does not work

I tried to map changing tabline mode to a key

local L = settings.mapleader

local mappings = {
  ['mode buffers'] = L .. 'mb',
  ['mode tabs'] = L .. 'mt',
  ['mode args'] = L .. 'ma',
  ['mode next'] = L .. 'mn',
}

tabline.mappings(mappings)

However, only mode next works well, and the other three doesn't work. Now, instead I have to use the cmdline commands to define my own mappings, e.g., nnoremap <leader>mb <Cmd>Tabline mode buffers.

Thank you.

Can I define highlights groups by myself?

It seems that I could not define these highlights directly, because tabline will override them once it is loaded. The reason is some themes provide a convenient API to define the colors between variants they provide.

For catppuccin:

custom_highlights = function(color)
  return {
    TFill = { fg = color.subtext0, bg = color.mantle },
    TSel = { fg = color.base, bg = color.overlay1 },
  }
end,

Then the highlights will be available for the four variants it provides.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.