less and vi fail on file whose name begins with +

Thomas Mueller mueller23 at insightbb.com
Mon Jul 16 09:11:42 UTC 2012


from Glen Barber <gjb at FreeBSD.org>:

> less(1) is expecting '+' to be followed by additional arguments.

> If you use 'less -- +DESC', for example, it should work fine.  Same with
> vi(1).

Yes, that works, as does "less ./+DESC".

Somehow I thought I had successfully done "less +CONTENTS" successfully before, but I must have preceded filename by path.

Less and vi failing when used directly on filename beginning with + is also true for Linux, I checked on Slackware 13.0.

Thanks to you and others for helpful responses.

Tom


More information about the freebsd-stable mailing list