Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 15 Dec 2011 23:44:15 -0500 (EST)
From:      vogelke+unix@pobox.com (Karl Vogel)
To:        freebsd-questions@freebsd.org
Subject:   Re: opening vim with a flag: ready to write?
Message-ID:  <20111216044416.23F7FBF66@kev.msw.wpafb.af.mil>
In-Reply-To: <20111215033334.GA10875@thought.org> (message from Gary Kline on Wed, 14 Dec 2011 19:33:34 -0800)
References:  <20111215004227.GA9075@thought.org> <201112150111.pBF1BKuB022106@mail.r-bonomi.com> <20111215033334.GA10875@thought.org>

next in thread | previous in thread | raw e-mail | index | archive | help
>> On Wed, 14 Dec 2011 16:42:31 -0800
>> Gary Kline <kline@thought.org> may have said:

G> is the a way of starting off vim or gvim and be able to type into the
G> editor _without_ first typing: a,i,o,O,I,A, or any other character?

   The command
       vim --cmd start /some/file
   works for new files, and puts you into insert mode on the first line of
   an existing file.

   If you want to have vim start by appending to an existing file, use
   something like
       echo >> /some/file
       vim + --cmd start /some/file

   to append a line first, or your session will start in "insert" mode with
   the cursor at the beginning of the last line.

-- 
Karl Vogel                      I don't speak for the USAF or my company

Leighton Meester beats her mom in court
              --Dec 2011 headline that really could have been phrased better



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20111216044416.23F7FBF66>