startprog.opt

Package: WA2L/WinTools 1.2.08
Section: Configuration Files (4)
Updated: 04 February 2023
Index Return to Main Contents

 

NAME

startprog.opt - configuration file for startprog

 

SYNOPSIS

WA2LWinTools/lib/startprog.opt

WA2LWinTools/lib/command.opt

 

AVAILABILITY

WA2L/WinTools

 

DESCRIPTION

This is the configuration file for the renamed variants of the startprog command.

The option file must have the same name as the related command variant ( e.g.: command.opt ).

 

FILEFORMAT

Rows starting with # are considered as comments.

The file format is OPTION=VALUE

Between the OPTION , the = and the VALUE are no spaces.

You can comment out any OPTION or completely remove the related setting line to use the default settings.

 

OPTIONS

VERBOSE
verbose output of the startprog command variant.

Example: VERBOSE=True

Default: VERBOSE=False

DISABLESTATS
if set to True disable command startup statistics collection. This option exists to avoid double recording when the started command already performs a statistics collection.

Example: DISABLESTATS=True

Default: DISABLESTATS=False

TYPE
type of the command to be started indirectly thru the startprog command variant.

Possible settings are: SYS, SYSTEM, SHELL, EXECSHELL, EXEC, JAVA@SYS, JAVA@SYSTEM, JAVA@SHELL , JAVA@EXECSHELL and JAVA@EXEC.

Where the JAVA@... types load the JAVA_PATH=path;path;path... from the optional etc/java.cfg configuration file to allow to define additional locations of the COMMAND=java.exe command on the system.

Example: TYPE=SYSTEM

Default: TYPE=EXEC

SHOWWINDOW
when set to True the configured command (COMMAND= command) is started in a window, when set to False the command is started completely in the background.

Example: SHOWWINDOW=False

Default: SHOWWINDOW=True

HIDECONSOLE
hide the console window, when not started from the command window (cmd.exe).

Example: HIDECONSOLE=False

Default: HIDECONSOLE=True

PATH
Extend system %PATH% to find additional commands.

In the PATH setting the environment variables %USERNAME%, %USERPROFILE%, %ProgramFiles%, %ProgramFiles(x86)%, %APPDATA%, %LOCALAPPDATA%, %INSTALLDIR%, %INSTALLDRIVE% and %ARCHITECTURE% can be used.

Where the %INSTALLDIR% variable contains the installation base directory of the WA2L/WinTools package, %INSTALLDRIVE% the drive letter (without colon) and the %ARCHITECTURE% is set to 32 on a 32-bit and to 64 on a 64-bit operating system.

Example: PATH=%USERPROFILE%\Documents\bin\FirefoxPortable;d:\bin\FirefoxPortable

Default: PATH=

PREEXEC
Command to be executed prior to the command specified in the COMMAND=command setting.

This might be useful to do some preparations prior to the command execution.

The PREEXEC command is always started as type SYSTEM.

Example: PREEXEC="%INSTALLDIR%\lib\WScheduler.cmd"

Default: PREEXEC=

COMMAND
command to be started thru the startprog command variant.

If this setting is a *.bat or *.cmd file, the TYPE=type shall be set to SYSTEM or SHELL.

If this setting is a *.exe or *.com file, the TYPE=type shall be set to EXEC.

In the COMMAND=... setting the same environment variables as in PATH=... can be used.

Example: COMMAND="%INSTALLDIR%\lib\Notepad2.exe"

Default: COMMAND=

OPTIONS
options to the COMMAND=command option, that are not provided thru the command line.

In the OPTIONS=... setting the same environment variables as in PATH=... can be used.

Example: OPTIONS=/o0 /f "%INSTALLDIR%\etc\Notepad2.cfg"

Default: OPTIONS=

WORKINGDIR
set specific working directory on startup.

Example: OPTIONS=%INSTALLDIR%\lib\folderspopup

Default: OPTIONS=

ESCAPEOPTIONS
escape options specified on command line.

Most likely this setting is needed on TYPE=SYSTEM when command line options containing special characters, as: (, ) and & have to be computed and a *.bat or *.cmd command is specified in the COMMAND=... setting.

Example: ESCAPEOPTIONS=True

Default: ESCAPEOPTIONS=False

VERSION
Version of started COMMAND to be displayed by the -V command line option (VERSIONOPT).

Example: VERSION=0.8.15

Default: VERSION=

AUTHOR
Author of started COMMAND to be displayed by the -V command line option (VERSIONOPT).

Example: AUTHOR=John Doe

Default: AUTHOR=

HELPOPT
Command line option to be used to display the usage message.

If HELPOPT is set empty, startprog will not display a usage message when invoking the -h option and passes that option to the command defined in the COMMAND setting. The usage display can then be handled by the started COMMAND.

Example: HELPOPT=

Example: HELPOPT=--help

Default: HELPOPT=-h

INSTALLOPT
Command line option to be used to install the COMMAND to the 'SendTo' or 'Autostart' menu.

If INSTALLOPT is set empty, startprog will not handle the installation and the option is also not listed when displaying the usage message after invoking the HELPOPT command line option.

Example: INSTALLOPT=

Example: INSTALLOPT=--install

Default: INSTALLOPT=-i

UNINSTALLOPT
Command line option to be used to remove the COMMAND from the 'SendTo' or 'Autostart' menu.

If UNINSTALLOPT is set empty, startprog will not handle the de-installation and the option is also not listed when displaying the usage message after invoking the HELPOPT command line option.

Example: UNINSTALLOPT=

Example: UNINSTALLOPT=--uninstall

Default: UNINSTALLOPT=-u

VERSIONOPT
Command line option to be used to display the version and author information defined in the VERSION and AUTHOR setting.

If VERSIONOPT is set empty, startprog will not handle the version display and the option is also not listed when displaying the usage message after invoking the HELPOPT command line option.

Example: VERSIONOPT=

Example: VERSIONOPT=--version

Default: VERSIONOPT=-V

MOREOPTIONS
additional options of the usage message. Multiple MOREOPTIONS=text lines are allowed.

Example: MOREOPTIONS=

Example: MOREOPTIONS=options

Default: MOREOPTIONS=[ options ]

MOREOPTDESC
description of the additional options in the usage output. Multiple MOREOPTDESC=text lines are allowed.

Example: MOREOPTDESC=

Example: MOREOPTDESC=-l list definitions

Default: MOREOPTDESC=[ options ] additional options

SHORTCUTLOC
Location of the shortcut that is created in the when using the INSTALLOPT command line option.

When SHORTCUTLOC is set to SENDTO COMMAND can be used thru the 'SendTo' menu.

If set to STARTUP it is installed to the 'Autostart' menu and the COMMAND will be executed 'On Login'.

If set to DESKTOP it is installed on the user's 'Desktop'.

Example: SHORTCUTLOC=STARTUP

Default: SHORTCUTLOC=SENDTO

SHORTCUTNAME
Prefix name of the 'SendTo' shortcut.

This prefix is seen in the 'SendTo' menu when SHORTCUTLOC=SENDTO is defined.

Example: SHORTCUTNAME= vi

Default: SHORTCUTDESC=command

SHORTCUTDESC
Description text of the shortcut.

This text is seen in the 'SendTo' menu when SHORTCUTLOC=SENDTO is defined.

Example: SHORTCUTDESC=enhanced Notepad

Default: SHORTCUTDESC=

SHORTCUTOPTS
Additional options for the shortcut.

In the SHORTCUTOPTS setting the same environment variables as in PATH= can be used.

Example: SHORTCUTOPTS=--verbose

Default: SHORTCUTOPTS=

SHORTCUTDIR
Set a specific start directory in the shortcut.

In the SHORTCUTDIR setting the same environment variables as in PATH= can be used.

Caution: do *not* set quotes ( ) around directories (even if there are spaces in a directory) and do *not* define a backslash ( \ ) at the end of a directory path.

Example: SHORTCUTDIR=%INSTALLDIR%\lib

Default: SHORTCUTDIR=

SHORTCUTMODE
Display mode of the command started thru the shortcut: 1: normal window, 3: maximized window, 7: minimized window.

Example: SHORTCUTMODE=1

Default: SHORTCUTMODE=7

 

EXAMPLES

1) example .opt file to start Notepad2 from bin/np.exe

#
# lib/np.opt - startprog options for: Notepad2
#
# [00] 01.07.2017 CWa   Initial Version
#

VERBOSE=False
COMMAND="%INSTALLDIR%\lib\Notepad2.exe"
OPTIONS=/o0 /f "%INSTALLDIR%\etc\Notepad2.cfg" +

VERSION=4.2.25
AUTHOR=Florian Balmer

 

SEE ALSO

wintoolsintro(1), java.cfg(4), startprog(3)

 

NOTES

-

 

BUGS

-

 

AUTHOR

startprog.opt was developed by Christian Walther. Send suggestions and bug reports to wa2l@users.sourceforge.net .

 

COPYRIGHT

Copyright © 2023 Christian Walther

This is free software; see WA2LWinTools/man/COPYING for copying conditions. There is ABSOLUTELY NO WARRANTY; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.


 

Index

NAME
SYNOPSIS
AVAILABILITY
DESCRIPTION
FILEFORMAT
OPTIONS
EXAMPLES
SEE ALSO
NOTES
BUGS
AUTHOR
COPYRIGHT

This document was created by man2html using the manual pages.
Time: 16:33:03 GMT, September 14, 2024