Subject: bin/24676: vi -c flag does not work correctly
To: None <gnats-bugs@gnats.NetBSD.org>
From: None <Peter.Bex@student.kun.nl>
List: netbsd-bugs
Date: 03/04/2004 22:53:26
>Number: 24676
>Category: bin
>Synopsis: The -c flag for letting vi automatically execute commands does not work correctly
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: bin-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Thu Mar 04 21:52:01 UTC 2004
>Closed-Date:
>Last-Modified:
>Originator: Peter Bex
>Release: NetBSD 1.6ZI
>Organization:
>Environment:
System: NetBSD frohike 1.6ZI NetBSD 1.6ZI (FROHIKE) #1: Tue Jan 27 01:47:06 CET 2004 airhead@frohike:/usr/obj/sys/arch/i386/compile/FROHIKE i386
Architecture: i386
Machine: i386
>Description:
When using the -c flag in vi to tell it to execute a command on startup, it
ignores it unless a file is passed as extra argument.
If this file is provided, the command is executed, but the cursor jumps to
the end of the file.
>How-To-Repeat:
$ vi -c "q"
$ vi -c "q" foo
[first command fires up vi, second quits immediately]
$ vi -c "set wl=72"
[in vi, "set wl" will show that wl is not set]
$ vi -c "set wl=72" foo
[in vi, the cursor is at end of file and "set wl" will show "wraplen=72"]
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted: