Discussion:
nvi and unicode
Thuban
2018-07-13 09:21:45 UTC
Permalink
Default vi (nvi) in OpenBSD doesn't handle correctly most of UTF-8
sings such as "é", "à" or so. One need to install nvi package to do so.
Is it planned to replace the vi binary in the future?
Is there any reason I can't think to keep this vi version?

Regards.
--
thuban
Predrag Punosevac
2018-07-13 14:06:19 UTC
Permalink
Post by Thuban
Default vi (nvi) in OpenBSD doesn't handle correctly most of UTF-8
sings such as "????", "?? " or so. One need to install
nvi package to do so.
Is it planned to replace the vi binary in the future?
Is there any reason I can't think to keep this vi version?
Regards.
--
thuban
If you read

https://en.wikipedia.org/wiki/Nvi

you should have noticed the following paragraph

"BSD projects continue to use nvi version 1.79 due to licensing
differences between Berkeley Database 1.85 and the later versions by
Sleepycat Software."

So the answer is no. nvi in the base of OpenBSD is further cleaned from
bugs beyond once upon a time common code. bcallah@ could shed more light
on the work on nvi from the base. Obviously if you need UTF-8 support
you have a choice of using package or two switching to DragonFly BSD
which has nvi2 in its base.

Cheers,
Predrag
Thuban
2018-07-13 16:42:04 UTC
Permalink
Thanks for enligthenment.
Post by Predrag Punosevac
Post by Thuban
Default vi (nvi) in OpenBSD doesn't handle correctly most of UTF-8
sings such as "????", "?? " or so. One need to install
nvi package to do so.
Is it planned to replace the vi binary in the future?
Is there any reason I can't think to keep this vi version?
Regards.
--
thuban
If you read
https://en.wikipedia.org/wiki/Nvi
you should have noticed the following paragraph
"BSD projects continue to use nvi version 1.79 due to licensing
differences between Berkeley Database 1.85 and the later versions by
Sleepycat Software."
So the answer is no. nvi in the base of OpenBSD is further cleaned from
on the work on nvi from the base. Obviously if you need UTF-8 support
you have a choice of using package or two switching to DragonFly BSD
which has nvi2 in its base.
Cheers,
Predrag
--
thuban
Anthony J. Bentley
2018-07-13 21:36:21 UTC
Permalink
Post by Thuban
Default vi (nvi) in OpenBSD doesn't handle correctly most of UTF-8
sings such as "é", "à" or so. One need to install nvi package to do so.
Is it planned to replace the vi binary in the future?
Is there any reason I can't think to keep this vi version?
nvi2's main deficiency is that it cannot handle invalid characters at
all: they interfere with display, searching, and writing. This is a big
change from base nvi which merely visually escapes non-ASCII characters.
In the past nvi2 has also had some pretty severe bugs including frequent
crashes and irreversible file truncation on :w which makes me wary of
bringing it in.

UTF-8 in OpenBSD's base vi is definitely a desired feature. The primary
blocker to implementing it is simply that nobody has done the work.
Loading...