Wednesday, February 28, 2024

Re: I had to replace gvim with neovim

On 2024-02-28, Steve Litt wrote:
> Hi all,
>
> The gvim program became too much of a hassle because it printed all
> sorts of GTk errors and warnings to the terminal, obliterating valuable
> information that was there. So I had to uninstall Vim and install
> neovim, which isn't as good, but all those GTk warnings were messing up
> my workflow.
>
> If anyone knows how to use gvim without all those GTk warnings, I'd
> like to hear it.

Hi Steve,

I can't test this because I don't get those warnings, but I'm
assuming they are printed to standard error. Try starting gvim this
way and see if the warnings go away.

$ gvim 2> /dev/null

If that works, then you can either create an alias like this in your
~/.bashrc, assuming your shell is bash:

alias gvim='2>/dev/null gvim'

or you can put the command in this shell script and put the shell
script in some directory in your PATH ahead of wherever gvim is,
e.g. in ~/bin.

#!/bin/sh
exec /usr/bin/gvim "$@" 2>/dev/null

That assumes that your gvim is in /usr/bin. If necessary, change
/usr/bin to the directory where your gvim resides. To find out, use

$ type gvim

Regards,
Gary

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/20240228144504.GJ26982%40phoenix.

No comments: