-
Notifications
You must be signed in to change notification settings - Fork 244
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: split from buffer view opens blank buffer (#898) #1004
fix: split from buffer view opens blank buffer (#898) #1004
Conversation
Hey @cseickel, this is broken. See the review I added above inside the code. |
@pysan3 I don't see any review or comments, an you link to them and/or repeat them here? |
Oh I see, your review is still pending @pysan3, no one else can see it until you submit it. |
I'll fix it. |
@@ -551,13 +551,14 @@ end | |||
---@param bufnr number|nil The buffer number to open | |||
M.open_file = function(state, path, open_cmd, bufnr) | |||
open_cmd = open_cmd or "edit" | |||
if open_cmd == "edit" or open_cmd == "e" then | |||
local cmd_for_buf = { edit = "b", e = "b", split = "sb", sp = "sb" } | |||
if open_cmd[cmd_for_buf] ~= nil then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be if cmd_for_buf[open_cmd] ...
.
It's the other way around.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now I can see it! 😄
Damn, this was my first time to use I think I was able to figure it out? Can you see it now? |
Fix an issue in buffer view, where a blank buffer would open instead of the selected buffer when using the
open_split
shortcut.More details on #898