Skip to content
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

Feature request: open in split #7

Open
t4t5 opened this issue Aug 23, 2023 · 3 comments
Open

Feature request: open in split #7

t4t5 opened this issue Aug 23, 2023 · 3 comments

Comments

@t4t5
Copy link

t4t5 commented Aug 23, 2023

This plugin is exactly what I was looking for since vim-fm's Joshuto integration doesn't seem to work, thank you! 🙏

One thing I'm missing atm is the ability to open files you're browsing in split view, so that you don't replace the file you're currently on. In rnvimr + ranger, you can do this with ctrl + v for example

@theniceboy
Copy link
Owner

I'm glad this plugin could help you. Unfortunately ctrl-v to open in split view requires some changes in joshuto itself. Joshuto has to detect that keypress and send a special signal (or write to a file) so this plugin can know.

@JohanChane
Copy link

How about using nvim_buf_set_keymap to set the shortcut for the buffer.

@imbolc
Copy link
Contributor

imbolc commented Oct 12, 2023

I've just added a setting to open files in new tabs in #9, would it be a solution to add opening in splits there and then just using different shortcuts in vim config:

// dt - to open in a tab
vim.keymap.set("n", "<leader>dt", ":lua require'joshuto'.joshuto({ edit_in_tab = true })<cr>", { silent = true })
// dv - to open in a vertical split
vim.keymap.set("n", "<leader>dt", ":lua require'joshuto'.joshuto({ edit_in_vsplit = true })<cr>", { silent = true })

It's not the best solution and probably would annoy to think about where to open in advance by still.

DreamMaoMao added a commit to DreamMaoMao/yazi.nvim that referenced this issue Jun 26, 2024
chore(doc): fix word spelling error
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants