[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
block_filter
command: <string>
The marked block is written to temporary file 1. The command is executed
with temporary file 1 as its standard input. The standard output is
collected in temporary file 2. The marked block is deleted and replaced by
the contents of temporary file 2. Both temporary files are then deleted.
The reserved comments are written using those appropriate for the current
buffer.
eg: block_filter "grep the"
The commands are executed via the "C" system() call. Therefore COMMAND.COM
or some other command processor should be accessible by the COMSPEC
environment variable on a DOS system. On OS/2 CMD.EXE should be
accessible.
If AE is executed with the -r option, it is running in 'restricted' mode,
and so will not shell out.
NOTE: Fold information is also passed through the filter command.
Therefore if you feed such data through a command like SORT the
resulting data may not form a correctly folded file.
eg: The argument fold File before SORT File after SORT
{{{ this fold /*...sthis fold:0:*/ contents
contents contents /*...e*/
}}} /*...e*/ /*...sthis fold:0:*/
Note that the resulting file has its end reserved comment before
its start! If you passed the above file through an
"uppercaseifier" then you would find that the reserved comments
would be "uppercaseified" as well. In the reserved comment ...s
implies closed fold, ...S would imply open. Therfore such a
command would, as a side effect, open all nested folds!
Moral: only use block_filter on text, unless you know the program
knows about folding.
NOTE: On UNIX and other environments, the commands you can give will vary
and indeed on some machines, this feature may not be available at all.
See Also:
other_shell
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson