IBM SC34-4499-03 Manual de usuario Pagina 233

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 356
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 232
v The resolved SOURCE file specifications
v The resolved TARGET specification
The exit keyword accepts any executable file or command. The exit program must
return an integer return value, zero meaning successful; it must also accept or ignore
the additional Gather parameters added to the end of the invocation string.
When used in the context of the RULE clause, exit keywords must follow the TARGET
keyword.
Using exit keywords: an example
In the following example, the first EXITPRIOR statement relates to the DATA clause and
specifies a user backup exit program, which executes before performing Gather copy
operations. This backup exit is passed two flags. The command stream executed in an
OS/2 shell is:
"e:\util\backup.cmd \i \t"
The second occurrence of the keyword illustrates how to use it in the context of a
RULE clause. In this example, an encryption program will run against each source file
specification. The exit program is passed the \k:347867 key option, the value for the
source specification, and the value for the target specification. In this example, the
command stream executed in an OS/2 shell is:
"encrypt \k:347867 d:\demoapp\a.exe f:\demoapp\bin":
The package file looks like this:
(DATA
(PACKAGEFORMAT gather)
(TARGETROOT d:\tcws)
(RULE
(SOURCE *.exe *.cmd)
(TARGET exe)
#|this program will be run for each source file|#
(EXITPRIOR encrypt \k:347867 )
)
(EXITPRIOR "e:\util\backup.cmd \i \t" )
)
Chapter 17. Using the Gather tool 213
Vista de pagina 232
1 2 ... 228 229 230 231 232 233 234 235 236 237 238 ... 355 356

Comentarios a estos manuales

Sin comentarios