This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
This allows you to specify an environment variable which must exist and whose
value is more PPWIZARD command line parameters.
This switch could be used to handle long command line, it effectively allows
you to have an infinitely long command line since the included contents can
itself refer to other environment variables.
ΓòÉΓòÉΓòÉ 2.15. /HTML ΓòÉΓòÉΓòÉ
Switch /HTML
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
This switch should rarely be required as html mode is the default mode unless
all input files end in the extension ".X" (its use is recommended for rexx
source code).
On non unix operating systems lines end with carriage return followed by
linefeed, with the internet unix has finally won (it only requires lines to
terminate with a linefeed). Web servers and browsers do not require the
carriage return (which they ignore). You can save an extra one character per
line with use of the /CRLF switch.
This switch sets the processing mode for the output file as well as the default
processing mode for other output files specified with the #Output command.
ΓòÉΓòÉΓòÉ 2.16. /HtmlGenerator ΓòÉΓòÉΓòÉ
Switch /HtmlGenerator:Contents
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
By default when generating HTML, ppwizard will try to insert a meta tag similar
to the following in the "HEAD" section:
<META NAME="GENERATOR" CONTENT="PPWIZARD version 99.231 on OS/2, FREE tool for OS/2, Windows, DOS and UNIX by Dennis Bareis (http://www.labyrinth.net.au/~dbareis/ppwizard.htm)">
You can turn off the generation of the tags altogether by specifying an empty
value or you can supply alternative line(s).
PPWIZARD is supplied as freeware and I would appreciate it if you at least
mention PPWIZARD and its homepage in the pages that you generate (either in
meta tags or comments). The switch is mainly supplied so that you can add your
own details if you wish.
If you wish to specify your own generator contents (or refer to ppwizard
details in HTML comments) you can make use of these variables (on the command
line replace '<' with '{x3C}' and '>' with '{x3E}') :
1. <?PpwizardAuthor>
2. <?PpwizardAuthorEmail>
3. <?PpwizardAuthorHomePage>
4. <?PpwizardHomePage>
The value you wish to give this switch is probably so large that you would
normally need to use the /GetEnv switch to get the information out of an
environment variable.
ΓòÉΓòÉΓòÉ 2.17. /Inc2Cache ΓòÉΓòÉΓòÉ
Switch /Inc2Cache[:YesOrNo]
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
This switch can be used to override the way PPWIZARD includes files. This would
not normally be required as PPWIZARD is likely to choose a good way.
If the "YesOrNo" parameter is not specified then it defaults to "Y", otherwise
one of the following values is expected:
Y
N
YES
NO
Warning
Loading the files to cache will of course require more memory than you'd
otherwise require. From what I gather Windows (95/98 and NT!) do not have very
good memory management.
ΓòÉΓòÉΓòÉ 2.18. /Info ΓòÉΓòÉΓòÉ
Switch /Info[:YesOrNo]
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
By default important informational messages may be output, these could be
considered as similar to a warning but no as severe. They inform you of
situations that are unusual but may be perfectly OK in your environment. This
switch allows you to turn these messages off.
It is recommended that you do not turn them off.
If the "YesOrNo" parameter is not specified then it defaults to "Y", otherwise
one of the following values is expected:
Y
N
YES
NO
ΓòÉΓòÉΓòÉ 2.19. /Other ΓòÉΓòÉΓòÉ
Switch /Other
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
This switch indicates that the input is not one of the types specifically
supported such as HTML or REXX. It turns of any funny stuff while in #AsIs
Mode.
This switch sets the processing mode for the output file as well as the default
processing mode for other output files specified with the #Output command.
ΓòÉΓòÉΓòÉ 2.20. /Option ΓòÉΓòÉΓòÉ
Switch /Option:OptionParameters
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
The "OptionParameters" is basically anything that is acceptable on the #option
command.
When PPWIZARD starts it sets up a default value for each option. This switch
allows you to modify the value to suit your needs.
Warning
You may need to be careful about some of the characters used on a command line
or when setting an environment variable. For example from an OS/2 command
prompt you can not set an environment variable to a value that contains an
equal sign, you would need to use '{x3D}' (it's ASCII code in hexadecimal)
instead.
ΓòÉΓòÉΓòÉ 2.21. /Output ΓòÉΓòÉΓòÉ
Switch /Output:EditMask
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
This parameter controls how the "InputFile" parameter is transformed to
generate the correct name for the generated output file. on
An edit mask is basically much like a file (with path if required) and will
contain zero or one special characters as follows:
1. * or {$BASE}
This gets replaced with the short filename (less extension) of the
current input file.
2. ? or {$PATH}
This gets replaced with the path (including terminating slash) of the
current input file. This is most likely to be of use if you want to
position generated files relative to the input file and you use the
"/ScanSubDir" switch. For example "?OUT\*.HTM".
3. {$path}
This allows you to set up a separate tree for generated filenames,
the input mask and file are examined and the relative path extracted,
the result is either blank ('') or a relative path that ends with a
path separator. Note for this to work the input mask must either use
an absolute path, begin with '.' or '..' followed by slash or not
have a path attached at all otherwise ppwizard will abort. It would
be pointless to use this sort of path unless the "/ScanSubDir" switch
was also used.
The "EditMask" can be absolute or relative (your exact circumstances will
determine your choice).
Note that resultant relative filenames are always relative to the current
directory.
While you control the case of the mask you can't control the case of the part
that replaces the '*'. What you can do is ensure the whole name is either in
upper or lower case with the /FileNames switch.
The default mask is "*.htm". I place all my output into a separate "OUT"
directory and use "/Output:OUT\*.HTM".
ΓòÉΓòÉΓòÉ 2.22. /Pack ΓòÉΓòÉΓòÉ
Switch /Pack[:YesOrNo]
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
This switch is only useful if "/rexx" is also specified. You can get a much
smaller generated rexx program by packing (off by default). Packing does not
significantly slow down processing.
If the "YesOrNo" parameter is not specified then it defaults to "Y", otherwise
one of the following values is expected:
Y
N
YES
NO
MORE ON PACKING
The preprocessor packs well written code (by my definition!) and can fail to
correctly pack code where strings are appended without the use of the "||"
operator (as the excess spaces will be removed). For example the following
statement will not create the string you expect when packed:
BothPartsCombined = 'Value:' TheValue;
The following statement is a version of the above that will work:
BothPartsCombined = 'Value: ' || TheValue;
You can get very good results by packing but if you have got legacy code or
you don't wish to change (your evil ways!) you should use the "/Pack:N"
command line switch. This turns off most packing (rexx comment and trailing
';' removal still occurs).
If you have trouble with some parts of your code but the bulk packs well then
you may wish to consider leaving packing on and using the AllowPack option to
indicate parts of your rexx code that should not be packed.
WARNING
This has not been tested on object rexx so I don't know if it will work or not
(I assume it will).
ΓòÉΓòÉΓòÉ 2.23. /Rexx ΓòÉΓòÉΓòÉ
Switch /Rexx
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
The input is treated as rexx source. Rexx comments are removed from the
source.
This switch sets the processing mode for the output file as well as the default
processing mode for other output files specified with the #Output command.
Packing of the resultant rexx code (within one generated line) occurs by
default. You can specify "/Pack" if you don't want this done. Turning off
packing will speed up the generation of rexx code but in my mind the
compression gain from leaving it on is worth it.
Other options you may wish to use are "LeaveBlankLines" & "KeepIndent".
WARNING
Note that if you are taking unknown code and passing it through the
preprocessor to reduce its size you should use the "/Pack;N" option as there
are situations where the operation of the code will be affected. Some good and
safe reduction in code size will still occur.
ΓòÉΓòÉΓòÉ 2.24. /SpellAddWord ΓòÉΓòÉΓòÉ
Switch /SpellAddWord:[-]NameOfAddFile
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
This option can be specified if you have used /SpellCheck (use empty dictionary
if required) to enable spell checking.
What it allows you to do is indicate which incorrect words should be added to a
dictionary file. All words you wish to add are added to the file sorted in
order of the number of occurances of this word so that the most frequently used
(therefore most important) are first.
You would typically manually cut and paste words from the generated file to one
of your dictionary files.
To automatically add all words to the file preceed the filename with "-".
ΓòÉΓòÉΓòÉ 2.25. /SpellCheck ΓòÉΓòÉΓòÉ
Switch /SpellCheck:NameOfDictionary
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
This option loads a dictionary and turns on spell checking. The switch can be
used any number of times to load as many dictionaries as you wish. As an
example you might wish to set up "GLOBAL.DIC", "PROJECT.DIC" and "JUNK.DIC".
You may need to set up "JUNK.DIC" to hold junk words that are not really valid
but get picked up as words during the spell check. In interactive spell
checking such as in Microsoft word, these junk words are the annoying ones you
keep replying "Ignore All" to!
Note that ppwizard ignores the case of words and should work for international
languages such as German.
The /SpellAddWord will help you update or create dictionaries.
A dictionary file must exist and it can be empty.
There are large dictionaries available (such as in isspell40.zip on hobbes)
however this take too long to load if you are impatient like me. The extra time
will be required to load the extra words into memory, once loaded I do not
think it will take longer to process your files.
Spell checking has 2 basic modes (you can use both together) as follows:,
You can indicate words that you frequently get wrong and ppwizard
will tell you when you use the word.
You can supply a list of "good" words (dictionaries) and ppwizard
will tell you if you use a word which is not in a dictionary.
Dictionaries
All leading whitespace on all lines is ignored as are any blank lines or lines
that begin with ';' (a comment).
There are two types of dictionary entries as follows:
1. A valid word. Each word occurs on its own line. The fact that we have
loaded at least one dictionary word (you are not required to do so)
means that ppwizard will try to validate (spell check) all words.
Note that a "word" can contain any characters and so if required
could be "ASD%^".
2. A '$command' as follows:
$MISTAKE
This command allows you to specify a word that you frequently
get wrong. Ppwizard will tell you if you use this word. The
command takes one or two parameters the first parameter is the
incorrectly spelt word while the second (if passed) is the word
correctly spelt.
$DELIMITERS
If you don't like the default delimiters that ppwizard uses then
you can specify a rexx expression which represents the
delimiters you wish to use. Each character you specify is
converted to a space and is therefore ignored. A warning is
generated if this command is used more than once.
Example of Dictionary
;--- Add common mistakes ----
$mistake seperate
;--- Specify alternate delimiters ----
$Delimiters d2c(9) || ',.=:;<>&-%()!/~?#${}[]"'
;--- A few words ----
THE
CAT
DOG
computer.
ΓòÉΓòÉΓòÉ 2.26. /SpellShowAll ΓòÉΓòÉΓòÉ
Switch /SpellShowAll[:YesOrNo]
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
By default you only see a warning for the first time a word error occurs in
each build. This switch allows you to indicate that you would like to see every
error.
If the "YesOrNo" parameter is not specified then it defaults to "Y", otherwise
one of the following values is expected:
Y
N
YES
NO
ΓòÉΓòÉΓòÉ 2.27. /ScanSubDir ΓòÉΓòÉΓòÉ
Switch /ScanSubDir
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
By default this program only checks the directory specified in the "InputMask",
specify this option if you wish to process subdirectories as well.
ΓòÉΓòÉΓòÉ 2.28. /Sleep ΓòÉΓòÉΓòÉ
Switch /Sleep:NumberOfSeconds
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
This option can be used to pause execution for a period of time after PPWIZARD
completes processing normally (no trap etc). Used with the "/DependsOn" switch
could be used in place of a CRON step to poll for data file changes.
If you like the sound of this be sure to also check out the "/Template" switch.
ΓòÉΓòÉΓòÉ 2.29. /Tabs ΓòÉΓòÉΓòÉ
Switch /Tabs:TabOption
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
The "TabOption" parameter controls how tabs if found are handled. Valid options
are:
Ignore
Don't do anything, just ignore, this may cause preprocessor to fail
(depending on where tabs are located).
ToSpaces
Each tab is converted to one only space.
Warnings
Each tab is converted to one only space and a warning is generated.
This is the default condition.
ΓòÉΓòÉΓòÉ 2.30. /Template ΓòÉΓòÉΓòÉ
Switch /Template:TemplateFile
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
Normally PPWIZARD begins by reading from the input file. This switch modifies
this behavior. The name of the "input file" is stored in the variable
"<?TemplateDataFile>" and the file named on this switch is loaded instead.
The template file would generally #include or #import the data file.
ΓòÉΓòÉΓòÉ 2.31. /WarningsIgnore ΓòÉΓòÉΓòÉ
Switch /WarningsIgnore[:IgnoreWhich]
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
This switch allows you to have individual control of which warning messages you
wish to see. If this switch is used more than once the last used invocation is
what is used. Warnings can come from PPWIZARD or from the #warning command.
To turn off ignoring of warning messages you would not pass a parameter. This
would be useful if you have set up a default where some messages are ignored.
If you supply a parameter then you can specify one or more strings (each
separated by ';', or ':' under unix). If the text of a warning message contains
any of the strings (case insensitive check) then the message will not display
and the warning return code will not be generated. If a message is dropped then
you can still see the message in debug mode as well as the reason it normally
gets dropped.
The warning message text which is searched includes the line number as well as
the warning ID, basically the exact text that you would normally see so you
could prevent warnings down to a particular line number if you wish (although
this is not recommended).
Warning IDs and text are not documented so you need to wait for one to occur
before deciding how to drop it.
If you wish to see warning messages but still want a zero return code you
should check out the /WarningsOk switch.
ΓòÉΓòÉΓòÉ 2.32. /WarningsOk ΓòÉΓòÉΓòÉ
Switch /WarningsOk[:YesOrNo]
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
By default when one or more warnings are displayed a return code of 1 will be
returned, when this switch is used to indicate that Warnings are OK then a
"good" return code of zero will be returned instead.
This switch simply indicates that you don't care what warnings were displayed,
you do not consider a warning to be an error. You can get more fine tuning
with the /WarningsIgnore switch.
If the "YesOrNo" parameter is not specified then it defaults to "Y", otherwise
one of the following values is expected:
Y
N
YES
NO
ΓòÉΓòÉΓòÉ 2.33. /**/ ΓòÉΓòÉΓòÉ
Switch /**/[:YesOrNo]
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
This switch only has affect when /rexx also used to turn on rexx processing.
Normally rexx comments on ends of lines are removed. Use this switch to leave
them in. Normally there would be no need to leave them in however you might
choose to do so to aid runtime debugging.
If the "YesOrNo" parameter is not specified then it defaults to "Y", otherwise
one of the following values is expected:
Y
N
YES
NO
ΓòÉΓòÉΓòÉ 2.34. /#Include ΓòÉΓòÉΓòÉ
Switch /#INCLUDE:FileList]
This is a PPWIZARD.CMD command line switch. You can set up your own default
switches in the "PPWIZARD_OPTIONS" environment variable.
This switch allows you to specify one or more files which should automatically
be included before any other file processing takes place. To specify more than
one they should be separated by a ';' character (or ':' under unix).
You could use this if you supply a set of macros in header file and supply a
batch file to run the preprocessor. You would then not have to require (or
request) a user of your header to '#include' it themselves.
#define QueryCategory 3 ;;This query is for this category
#define LinkTemplate <P><A HREF="{$url}">{$title}</A>: {$description} ;;HTML for each record (note that it would be more efficient (but less "clean") to just pick up rexx variable names here
;--- Enable PPWIZARD to make use of external SQL library --------------------
This is the name of the text file that includes the example. This can
be unmodified code.
FRAGMENT
If you don't want to include the whole file then you must mark the
start and end lines with a unique string. Only the part between these
lines will be included. This allows you to set up a larger file
containing all your examples in one place if that is your wish.
INDENT
Normally everything is indented a small amount. You may wish to
remove the indent or even make it bigger. The value you supply is the
number of leading spaces you require.
SPELL
Normally spell checking is not allowed to occur in examples. You can
specify "ON" if you wish to allow it or "OFF" if not. Note that this
does not turn on spell checking it just indicates if spell checking
is allowed.
ASIS
All "normal" characters are already taken care of such that they will
correctly display in a browser, for example when generating html "<"
is converted to "<". If you find other characters you'd also like
automatically taken care of you can define these (international
characters might need more work). Have a look at the #AsIs command,
it shows you how to set up the modifications. This parameter can
take one or more space separated previously setup ASIS state names.
STATE
The contents of this parameter are used in a "#AutoTagState +"
command. If you don't want the automatic tagging you previously set
up to occur then don't pass this parameter. You would normally pass
"REMEMBER" to have them occur.
EXAMPLE - Source
This example shows some HTML source code.
;--- Create a new clear state, set up new ASIS state, restore state ---
#AutoTagState +
;--- Set up aliases for all dangerous character so that they display OK in browser ---
#if ['<$DocType>' = 'HTML']
;--- HTML being generated ---
#RexxVar "UMLAUT" =x= "ü" ;;Map an alias (for our use) to the output text
#elseif
;--- IPF being generated ---
#RexxVar "UMLAUT" =x= "Ъ" ;;This char OK as is in IPF
#endif
;--- We defined aliases above only so that we more easily refer to strings, for example an umlaut looks the same in IPF and HTML until alias replaced ---
#AutoTag "Ъ" "<?xUMLAUT>" ;;Now map char to our alias
;--- Create named ASIS state called "DANGEROUS" ---
#AsIs SETUP DANGEROUS
#AutoTagState -
;--- Now lets also set up some automatic tagging, adding to existing tagging (only applies to this example otherwise we'd not do it here) ---
#AutoTagState + Remember ;;Adding to existing tags (remember current)
#AutoTag ^Gr<?xUMLAUT>n^ ^<$DarkGreen Text='Gr<?xUMLAUT>n'>^ ;;Because we used aliases we don't need to check if html/ipf etc to do this step
;--- Load the example (a part of the file - fragment) ---