Loading ...
Sorry, an error occurred while loading the content.

39683Re: Starting gvim without GUI

Expand Messages
  • Bram Moolenaar
    Apr 27, 2005
      Gautam Iyer wrote:

      > > >My system has vim complied (without GUI, and normal feature list) in
      > > >/usr/bin/vim. It also has vim compliled (with GUI, huge features, perl
      > > >python etc) in /usr/bin/gvim. On the rare occasion I need to use one the
      > > >perl/python interface, I have to use gvim. But I *don't* want to start
      > > >the GUI. Is there any way I can do this?
      > > >
      > > >"vim -g" will start the gui. However there is no corresponding option to
      > > >"not start" the GUI if the program name is gvim. I can ofcourse put a
      > > >symlink called "vim-huge" in my ~/bin directory pointing to
      > > >/usr/bin/gvim. But I'd like to avoid that ... (and hoping a command line
      > > >option will be added to acomplish this task).
      > >
      > > Being on a Unix-like system, you stand already better than someone on
      > > W32 (where it is _not_ possible to start in console mode a version of
      > > Vim with GUI compiled-in).
      > >
      > > I see two possible solutions to your questions:
      > >
      > > Method 1: Move your gvim executable to the X11 executable directory
      > > under the name vim (and with a softlink gvim -> vim pointing to it). You
      > > can then invoke it in console mode with an explicit path, something like
      > > /usr/X11/bin/vim (or whatever).
      > >
      > > Method 2: Use a softlink vim (or vim-something) -> /usr/bin/gvim. That
      > > softlink could be named ~/bin/vim-huge or even ~/vim (out of your
      > > $PATH, and call it explicitly as ~/vim).
      > Thanks for the suggstions all. I guess there's no way out of doing some
      > kind of symlink trick or fooling gvim into thinking there's no X server
      > running. Unless ofcourse I patch the code myself and add the above
      > command line option ... :)

      Doesn't the "-v" argument do what you want? "gvim -v" runs like "vim",
      no GUI.

      ARTHUR: Who are you?
      TALL KNIGHT: We are the Knights Who Say "Ni"!
      BEDEVERE: No! Not the Knights Who Say "Ni"!
      "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD

      /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
      /// Sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
      \\\ Project leader for A-A-P -- http://www.A-A-P.org ///
      \\\ Buy LOTR 3 and help AIDS victims -- http://ICCF.nl/lotr.html ///
    • Show all 7 messages in this topic