Comments (4)
I've resolved this issue by myself, the tab didn't close because I just did :tabclose but I didn't do :BufferClose
from barbar.nvim.
I've resolved this issue by myself, the tab didn't close because I just did :tabclose but I didn't do :BufferClose
Actually I didn't resolve this issue, I added map('n', '', 'BufferClose tabclose ', opts) to my config but when I press alt+w, it didn't work. It closes the buffer but sometimes it can't close the tab.
from barbar.nvim.
Just so I understand, you want a command which can close a tab and the buffer associated with it?
The problem with the mapping, I suspect, is the lack of VimL's equivalent to a semicolon (|
) between statements:
map('n', '<A-w>', 'BufferClose | tabclose ', opts)
If that doesn't work, you can try:
vim.keymap('n', '<A-w>', function()
vim.cmd.BufferClose()
vim.cmd.tabclose()
end, opts)
The builtin :bdelete
command might also just remove tabs by itself, I'm not sure. Try that as well.
from barbar.nvim.
Just so I understand, you want a command which can close a tab and the buffer associated with it?
The problem with the mapping, I suspect, is the lack of VimL's equivalent to a semicolon (
|
) between statements:map('n', '<A-w>', 'BufferClose | tabclose ', opts)If that doesn't work, you can try:
vim.keymap('n', '<A-w>', function() vim.cmd.BufferClose() vim.cmd.tabclose() end, opts)The builtin
:bdelete
command might also just remove tabs by itself, I'm not sure. Try that as well.
thanks, it works
from barbar.nvim.
Related Issues (20)
- Show Only Pinned Buffers HOT 7
- empty buffer is focused on startup with '%' in shada HOT 6
- Customizable `auto_hide` count HOT 3
- Question: Is there a way in barbar to disable creating buffer tabs and only enabling tabs? HOT 1
- Switch to last visited tab HOT 3
- Barbar command cannot be executed when I opened a python file using Neovim (Label: bug) HOT 8
- Highlight background color HOT 5
- Remove `bufferline` folder HOT 4
- Closing a term buffer with BufferClose errors requiring a ! to override HOT 3
- Support centering & coloring the offset text HOT 2
- Add highlight for the pin icon HOT 4
- Hiding the tabline on my start screen HOT 4
- Quit when calling BufferClose for single tab HOT 5
- Error: notfound key underdouble HOT 1
- [QUESTION]: Group windows inside a single tab? HOT 2
- Closing buffers very quicky causes consistent UI glitch for barbar.nvim HOT 6
- Highlight colors inconsistent between buffers HOT 3
- No devicons for .txt files HOT 14
- Can't get BufferPickDelete working HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from barbar.nvim.