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

Vertical split preview window #38

Open
cazgp opened this issue Nov 16, 2018 · 6 comments
Open

Vertical split preview window #38

cazgp opened this issue Nov 16, 2018 · 6 comments

Comments

@cazgp
Copy link

cazgp commented Nov 16, 2018

Is it possible to open the preview window vertically?

I run the command, c-w H to move it vertical to see the results, start typing to amend the query, and then the preview autocloses after a few seconds. I could easily write a function that runs the DB command and then does the split move, but I was wondering if you think making it an option makes sense?

@tpope
Copy link
Owner

tpope commented Nov 16, 2018

I don't like options for stuff like this, but support for <mods>, which would enable :vert DB, would be a nice enhancement.

@cazgp
Copy link
Author

cazgp commented Nov 18, 2018

Yeah that would great :) I did wrap the DB call in a function which does the c-w H automatically, but it ruins the layout when there are multiple splits open. Easily solved by two functions, but support out the box would be cool.

Also (sort of related) the dadbod split auto-closes for some reason. Do you know if dadbod is auto-closing or if that's a vim thing? I'm unsure how to work it out!

@tpope
Copy link
Owner

tpope commented Nov 18, 2018

Auto-closes when? Dadbod doesn't close it but there are reasons Vim would (:pclose for example).

@cazgp
Copy link
Author

cazgp commented Nov 19, 2018

It's fairly reproducible:

$ vim test.sql
i SELECT * FROM users;
V :DB
o
SEL << at that point the DB window closes.

I've tried it with waiting and nothing happens, so it seems to be something linked to typing but I can't work it out. But if you don't think it's dadbod related then it must be some other plugin being funky!

@tpope
Copy link
Owner

tpope commented Nov 19, 2018

Sounds like an autocomplete plugin.

@washtubs
Copy link

I have the same issue. It's definitely caused by deoplete.

I'm just doing this right now, which completely destroys deoplete for the whole vim instance, but it works for me cause I only work on sql files in their own separate vim instances anyway.

autocmd FileType sql autocmd! deoplete *

johnrembo pushed a commit to johnrembo/vim-dadbod that referenced this issue Feb 5, 2023
Column completion for sqlite
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

3 participants