Skip to content

Macvim in console mode hangs with custom viminfo location #752

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

Closed
chdiza opened this issue Sep 25, 2018 · 4 comments · Fixed by #780
Closed

Macvim in console mode hangs with custom viminfo location #752

chdiza opened this issue Sep 25, 2018 · 4 comments · Fixed by #780

Comments

@chdiza
Copy link
Contributor

chdiza commented Sep 25, 2018

I have a wrapper script that does exec somestuff "$@", where somestuff calls the Vim binary inside of MacVim. This wrapper's been working fine for a long time, so I don't think it's the problem.

As of (at latest) MacVim 8.1.425, if I call that embedded Vim binary and have the line se vi='20,<0,s10,h,n~/.tmp/viminfo in my vimrc, then Vim will hang if I make some app other than the terminal active and try to click back into the terminal.

If I omit the last part of &vi setting the custom location, there is no hang.

Also, there is no hang at all, ever, using upstream Vim.

The hang happens in both iTerm2 and Terminal.app

This is on High Sierra 10.13.6 and a MacVim built with Xcode 10.

@chdiza
Copy link
Contributor Author

chdiza commented Sep 25, 2018

A vimrc that contains only se vi+=~/.tmp/viminfo will cause the hang.

(Obviously you have to make sure that the dir .tmp exists first).

@chdiza
Copy link
Contributor Author

chdiza commented Sep 25, 2018

I had suspected Xcode 10 of being a cause, but I can reproduce on a different High Sierra machine that still only has Xcode 9.4.1.

@chdiza
Copy link
Contributor Author

chdiza commented Sep 25, 2018

I have manually bisected, and it required going to a machine with Xcode 9.4.1 because the bug is old.

The first bad commit is fa3b48c, "Control sharing the find pasteboard with defaults"

@chdiza
Copy link
Contributor Author

chdiza commented Sep 25, 2018

To see the bug, one needs MMShareFindPboard set to -bool false. I've had it set that way the whole time. If I turn it on, the bug doesn't manifest.

I don't like that setting turned on, because it makes a bunch of vim search patterns (which often have regex stuff in them) show up in the search boxes of other Cocoa apps, where those search patterns are useless.

I guess the custom location of a viminfo file is relevant because (at least in part) that viminfo file has the last search pattern stored in it. My guess is that console-MacVim is choking on that for some reason.

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

Successfully merging a pull request may close this issue.

1 participant