home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 5 Edit
/
05-Edit.zip
/
vile-src.zip
/
vile-8.1
/
doc
/
w32modes.doc
< prev
Wrap
Text File
|
1998-07-10
|
5KB
|
121 lines
Written June 2, 1998
Setting Win32-Specific Modes
============================
The values of the "w32pipes" and "force-console" modes significantly affect
the editor's interactions with the shell. The good news is that the editor
optimally sets these modes when the host OS is Windows NT. Consequently,
if NT is your only expected operating environment, the remainder of this
document is of no interest. Otherwise, you plan to use Windows 95/98 and
should definitely continue reading.
Note: For the remainder of this document, a generic reference to "vile"
refers to both the console and GUI editor, unless otherwise stated.
Background
==========
Command.com, the shell supplied with the original version of Windows 95,
exhibits many, many problems when communicating with another application
via an anonymous pipe. Consequently, w32pipes and force-console were
created to permit the user to avoid as many of those problems as possible.
After the initial Windows 95 release, Microsoft eventually rolled out a
bugfix called OSR2. However, OSR2 is only available from OEM's (e.g.,
Dell, Gateway, etc.) for distribution with a new PC. It's not known if any
of command.com's anonymous pipe bugs were fixed in that release of the OS.
And, of course, Windows 98 will be released in a matter of days, which
may or may not solve command.com's problems.
w32pipes
========
This boolean mode, if set, enables native anonymous pipe communication
between the editor and the shell for the following operations:
:r !<cmd> (read pipe)
:w !<cmd> (write pipe)
<filter region> (e.g., !}fmt)
^X-!
If not set, the above operations are instead emulated via temporary files.
force-console
=============
If w32pipes is set, then winvile (only) consults force-console to decide
whether or not to explicitly create a console prior to initiating a read
pipe or filter region operation.
Trade-Offs
==========
If using console vile and command.com (i.e., not using a replacement shell),
w32pipes must _not_ be set. This means that pipe operations will be effected
with temporary files. Unfortunately, write pipes simply don't work via
temporary file communication. Note that some replacement shells (e.g.,
Thompson Toolkit) don't exhibit anonymous pipe bugs and w32pipes may
safely be set in that case (assuming, of course, that the environment
variable COMSPEC has been modified to specify the replacement shell).
If using winvile, w32pipes and force-console _must_ be set for all shells
and versions of Win95 tested to date. If w32pipes is not set, _all_ pipe
operations will fail and if force-console is not set, the editor will hang.
However, if w32pipes is set and command.com is used as the shell, the
floppy will be accessed during each pipe operation. Additionally,
setting force-console causes each read pipe and filter region operation to
briefly pop up and pop down a black, background console. Got that :-) ?
Configuring Winvile and Vile via Vile.rc
========================================
~if ¬ &sequal "Windows_NT" &env "OS"
; Assume host is win95
~if &sequal $progname "winvile"
set force-console
set w32pipes
~elseif &equal 0 &sindex &lower $shell "command.com"
; shell is not command.com--assume it's 32-bit and can handle
; native pipe operations
set w32pipes
~else
; shell is command.com--native pipes not a good idea
set now32pipes
~endif
~endif
Optimum Console Vile Settings
=============================
Entries in the table marked ? have not been tested. If your host
environment matches an untested entry in the table and you have validated
various mode settings, please send your results to the "vile-bugs" mailing
list: vile-bugs@foxharp.boston.ma.us .
shell w32pipes force-console trade-offs
NT4.0 any 32-bit set N/A no problems
Win95 command.com unset N/A no write pipes
Win95 Thomp Toolkit set N/A no problems
OSR2 ? ? N/A ?
Win98 ? ? N/A ?
Optimum Winvile Settings
========================
Entries in the table marked ? have not been tested. If your host
environment matches an untested entry in the table and you have validated
various mode settings, please send your results to the "vile-bugs" mailing
list: vile-bugs@foxharp.boston.ma.us .
shell w32pipes force-console trade-offs
NT4.0 any 32-bit set unset no problems
Win95 command.com set set floppy grinds, transient console
Win95 Thomp Toolkit set set transient console
OSR2 ? ? ? ?
Win98 ? ? ? ?