Previous[ | Contents] | Index |
5Creates a new queued replacement in the VDE database.
5CREATE REPLACEMENT rep-name [, rep-name...]
rep-name
FThe name of the new replacement to be created. This name can be up to 339 characters long and must follow VDE name syntax.
HWhen a user has reserved and modified one or more modules and then uses 8the REPLACE command to replace the modules into the VDE 7libary, VDE either replaces the modules immediately or Hcreates a queued replacement for them. A queued replacement is a record <in the VDE database that records that the modules should be Hreplaced into the library at a future time, after the modules have been Breviewed and when an authorized user enters a PERFORM REPLACEMENT Fcommand for the replacement. Whether the REPLACE command replaces the Gmodules immediately or creates a queued replacement is determined by a Hqualifier to that command or by an attribute on the streams affected by the replacement.AAlthough queued replacements are normally created by the REPLACE Fcommand when you replace modules, you can create a queued replacement Gdirectly with the CREATE REPLACEMENT command. After you have created a Fqueued replacement with this command, you can add module reservations Fto the replacement with the REPLACE command by using the /REPLACEMENT *qualifier to specify the replacement name.
/LOG (default)
/NOLOG
EControls whether log messages are printed after the new replacements Fare created. The /LOG qualifier causes the messages to be printed and Fthe /NOLOG qualifier suppresses them. The messages indicate that each Gnew replacement has been created and that the database transaction has successfully committed./REMARK="string"
DSpecifies a remark string to be stored for the new replacement. The Bquoted remark string, which can be up to 132 characters long, may Gcontain any explanatory remark about the new replacement that you want stored in the VDE database.EAlthough this qualifier is required, you can specify an empty remark 9string. If you do not specify the /REMARK qualifier, VDE prompts you for a remark string.
6
#1 |
---|
:VDEä CREATE REPLACEMENT NEWREP/REMARK="Replacement remark"9%VDE-I-REPADDED, replacement NEWREP added to the database>%VDE-I-COMMIT, database transaction has successfully committedVDEäBVDEä REPLACE/QUEUE/REPLACEMENT=NEWREP A.REQ "Fix access violation"C%VDE-I-FILCOPSTAG, file DEV$:[MYDIR]A.REQ;13 copied to staging area@%VDE-I-REPLQUE, module [CODE]A.REQ queued for replacement NEWREP>%VDE-I-COMMIT, database transaction has successfully committedVDEäVDEä PERFORM REPLACEMENT NEWREPH%VDE-I-REPLACED, generation [CODE]A.REQ;8(6A2) replaced into stream V2.0,%VDE-I-REPPERF, replacement NEWREP performed>%VDE-I-COMMIT, database transaction has successfully committedVDEä |
EThis example creates a new replacement called NEWREP and specifies a Fremark string for it. The REPLACE command then adds a reservation for >module [CODE]A.REQ to the replacement. The subsequent PERFORM >REPLACEMENT command replaces that module into the VDE library.
)Creates a VDE script in the VDE database.
!CREATE SCRIPT file-spec
file-spec
BSpecifies the OpenVMS file specification for a file that contains Dthe text of the new script. If you omit the directory specification Dfrom the file-spec parameter, your current default >directory is assumed. If you omit the file extension from the Bfile-spec parameter, file extension VDESCRIPT is assumed.
=The CREATE SCRIPT command reads a VDE script from a file and 7records the script and its type in the VDE database. A =script is a sequence of commands in the VDE =script language that VDE can execute to create a DCL command 5file. VDE can then invoke that DCL command file in a 9subprocess to perform the action of the script. VDE uses Ascripts to perform many different kinds of actions. For example, =VDE uses "compile scripts" to compile modules in a @build job. Similarly, it uses "new-stream scripts" to Epopulate the directories of a new stream with files when it performs Fthe CREATE STREAM command. There are many other kinds of scripts, all Edistinguished by the commands or circumstances that cause them to be invoked.:The primary purpose of VDE scripts is to insert names and =directory specifications from the VDE database into text you Fspecify to generate DCL command files that perform various actions. A >VDE script is thus a mixture of plain text and invocations of Efunctions that retrieve names (such as module names, type names, and Efacility names) and directory strings (such as the names of facility &subdirectories) from the VDE database.
<Since you define scripts, you define how VDE should perform Gthe corresponding actions. For example, you decide how a Pascal module Eis compiled because you define the Pascal compile script. Similarly, Fyou can define a script that defines auxiliary actions of the REPLACE Acommand. Scripts thus let you make policy decisions for your own :project, while VDE provides the mechanisms that implement your policies.
FThe CREATE SCRIPT command only defines the new script for the current Gdefault development stream. You can reference the new script only from Hwithin the stream to which it belongs. When you want to create the same Hscript for more than one stream, you must use the CREATE SCRIPT command Hfor each stream. For each stream, first enter the SET STREAM command to Dset the development stream, then enter the CREATE SCRIPT command to ,create the desired script within the stream.
FWhen a new development stream is created, all script definitions from Cthe parent stream are copied to the child stream. If modified, the Dscript definitions then evolve independently in the two development streams.
|Keywords used within scripts are documented in Script Keywords, while yscript functions are in Script Functions, and script types are in mScript Types. For other script-related commands, also see DELETE SCRIPT, EXTRACT SCRIPT, INVOKE SCRIPT, MODIFY SCRIPT, and @SHOW SCRIPT.
/BUILD
:Specifies that the script be invoked when VDE starts each @process that executes a build job. The VDE$BUILD utility, which executes buildEjobs, invokes the script once for each process that executes a given Bbuild job. This script runs before the process executes any build Gsteps. The script can be used to generate DCL that defines commands or Glogical names that are needed by subsequent build steps. BUILD scripts 7are optional and are not needed for build jobs to work./COMPILE=mod-name
9Specifies that the script be invoked when VDE compiles a =module that matches the mod-name parameter. >VDE invokes the script when you enter a COMPILE command for a Cmatching module or run a build job that contains compile steps for Amatching modules. The script must generate the DCL commands that "actually perform the compile step./COPY=mod-name
>Specifies that the script be invoked when VDE copies a module :that matches the mod-name parameter. VDE Ginvokes the script when you enter a COPY command for a matching module For run a build job that contains copy steps for matching modules. The Escript must generate the DCL commands that actually perform the copy step./CREATE_FACILITY
7Specifies the script that VDE should invoke when a new -facility is created. This script is optional.$/DELETE_GENERATION=mod-name
8Specifies that the script be invoked when VDE deletes a 8stream's latest generation of a module that matches the <mod-name parameter. VDE invokes the script Fwhen you enter a DELETE GENERATION command for a matching module. The Hscript should perform auxiliary processing that you want for the DELETE BGENERATION command, such as updating source files in a clear-copy Edirectory. This type of script is optional and is not needed for the "DELETE GENERATION command to work./FETCH=mod-name
8Specifies that the script be invoked when VDE fetches a =module that matches the mod-name parameter. <VDE invokes the script when you enter a FETCH command for a Fmatching module. The script should generate DCL commands that perform Bauxiliary processing that you want for the FETCH command, such as Bsending notification to interested individuals. FETCH scripts are :optional and are not needed for the FETCH command to work.$/INSERT_GENERATION=mod-name
8Specifies that the script be invoked when VDE inserts a Bgeneration of a module that matches the mod-name <parameter into a development stream. VDE invokes the script Gwhen you enter an INSERT GENERATION command for a matching module. The Hscript should perform auxiliary processing that you want for the INSERT BGENERATION command, such as updating source files in a clear-copy Edirectory. This type of script is optional and is not needed for the "INSERT GENERATION command to work./LINK=mod-name
=Specifies that the script be invoked when VDE links a module :that matches the mod-name parameter. VDE (invokes the script when you enter a LINKE command for a matching module or run a build job that contains link G steps for matching modules. The script must generate the DCL commands % that actually perform the link step./LOG (default)
/NOLOG
GControls whether log messages are printed after the script is created. EThe /LOG qualifier causes such messages to be printed and the /NOLOG Gqualifier suppresses them. These messages indicate that the script has =been created and that the database transaction has committed successfully./NEW_STREAM=fac-name
HSpecifies that the script be invoked for each facility that matches the ;fac-name parameter when VDE creates a new =development stream. VDE invokes the script for each matching Afacility when you enter a CREATE STREAM command. The script must Fgenerate DCL commands that copy all stream-specific files for a given Bfacility from the parent stream's directories to the new stream's Cdirectories. The role of NEW_STREAM scripts is to populate the new Gstream's directory tree with all relevant files from the parent stream.BNEW_STREAM scripts are optional and are not needed for the CREATE BSTREAM command to work, but they are strongly recommended because Gminimal system builds for the new stream cannot work unless all result Gfiles (such as object libraries and executable images) are copied from *the parent stream to the new child stream.
/NOKEEP=mod-name
9Specifies that the script be invoked when VDE replaces a =module that matches the mod-name parameter. =VDE invokes the script when you enter a REPLACE command with Hthe /NOKEEP qualifier for a matching module. The script should generate GDCL commands that perform the action of the /NOKEEP qualifier, such as Ddeleting the replaced source module and perhaps also the associated Gobject and listing files from the user's default directory. The script Gis run after the REPLACE command's database transaction has committed; Bit thus performs "clean-up" operations for the command. GNOKEEP scripts are optional and are not needed for the REPLACE command Fto work. (If a NOKEEP script is not defined when a module is replaced ;with the /NOKEEP qualifier, VDE does not delete any files.)/REMARK="string"
CSpecifies a remark string to be stored in the database for the new Dscript. The quoted remark string, which can be up to 132 characters Hlong, may contain any explanatory remark about the script that you want to store in the database./REPLACE=mod-name
9Specifies that the script be invoked when VDE replaces a =module that matches the mod-name parameter. >VDE invokes the script when you enter a REPLACE command for a Fmatching module. The script should generate DCL commands that perform <auxiliary processing that you want for the REPLACE or (on a Hqueued-replacement stream) PERFORM REPLACEMENT command, such as sending Dnotification to interested individuals or copying object modules to Fobject libraries. REPLACE scripts are optional and are not needed for the REPLACE command to work./RESERVE=mod-name
9Specifies that the script be invoked when VDE reserves a =module that matches the mod-name parameter. >VDE invokes the script when you enter a RESERVE command for a Fmatching module. The script should generate DCL commands that perform Dauxiliary processing that you want for the RESERVE command, such as Dsending notification to interested individuals. RESERVE scripts are <optional and are not needed for the RESERVE command to work./SEGMENT=seg-num
4Specifies the segment number of the new script. The Aseg-num parameter, which specifies the script's Gsegment number, must be an integer value in the range from 1 to 20. If 7you omit this qualifier, VDE uses segment number 10 by 8default. When VDE later invokes scripts to perform some Gaction, it generates the segments of the DCL command file from scripts !ordered by their segment numbers./SET_FACILITY=fac-name
9Specifies that the script be invoked when VDE sets a new Gdefault facility that matches the fac-name parameter. <VDE invokes the script when you enter a SET FACILITY or SET HCONTEXT command for a matching facility. The script should generate DCL Ecommands that perform auxiliary processing that you want for the SET AFACILITY or SET CONTEXT command, such as defining logical names. ASET_FACILITY scripts are optional and are not needed for the SET (FACILITY or SET CONTEXT command to work./This qualifier is not yet implemented.
/SET_STREAM
9Specifies that the script be invoked when VDE sets a new <default stream. VDE invokes the script when you enter a SET GSTREAM or SET CONTEXT command. The script should generate DCL commands Fthat perform auxiliary processing that you want for the SET STREAM or HSET CONTEXT command, such as defining logical names. SET_STREAM scripts Bare optional and are not needed for the SET STREAM or SET CONTEXT command to work./This qualifier is not yet implemented.
/STAGING=mod-name
>Specifies that the script be invoked when VDE copies a source Cmodule that matches the mod-name parameter into a :"staging" area. VDE invokes the script when you Eenter a REPLACE command for a matching module and the replacement is queued. For a7queued replacement, VDE copies each replaced file to a >staging area, from where it is actually replaced into the VDE Flibrary when another user later enters a PERFORM REPLACEMENT command. DThe script must generate DCL commands that copy the module into the staging area./UNRESERVE=mod-name
;Specifies that the script be invoked when VDE unreserves a =module that matches the mod-name parameter. ;VDE invokes the script when you enter an UNRESERVE command Dfor a matching module. The script should generate DCL commands that Fperform auxiliary processing that you want for the UNRESERVE command, Bsuch as sending notification to interested individuals. UNRESERVE Escripts are optional and are not needed for the UNRESERVE command to work.
6
#1 |
---|
$ TYPE [MYDIR]SCRIPT_C.VDESCRIPT! Script to compile a C module.!EMIT "$ SET VERIFY"&EMIT "$ DEFINE/NOLOG SRC$ ", $DIR(SRC)&EMIT "$ DEFINE/NOLOG OBJ$ ", $DIR(OBJ)3EMIT "$ CC/DEBUG/OBJ=OBJ$:/ANA=OBJ$: SRC$:",$MODTYP'EMIT "$ VDE/DEPEND C OBJ$:",$MOD,".ANA"EXIT$ VDE=VDEä CREATE SCRIPT/COMPILE=[RMS]*.C [MYDIR]SCRIPT_C.VDESCRIPTL%VDE-I-SCRPADDED, script from file DEV$:[MYDIR]SCRIPT_C.VDESCRIPT;9 added to the database/ script to compile module [RMS]*.C (segment 10)>%VDE-I-COMMIT, database transaction has successfully committedVDEä |
66In this example, the user first types the script file D[MYDIR]SCRIPT_C.VDESCRIPT on the terminal. The script contains five @EMIT commands followed by an EXIT command. The user then enters <VDE and uses the CREATE SCRIPT command to enter that script ;file into the VDE database as the compile script for all C Fmodules in facility RMS. The log messages confirm that the script was 'successfully entered into the database.
#2 |
---|
%$ TYPE [MYDIR]SCRIPT_LINK_X.VDESCRIPTF! VDE script to generate the DCL commands needed to link module X.EXE.!EMIT "$ SET VERIFY"'EMIT "$ DEFINE OBJLIB ", $DIR(OBJ,CODE)2EMIT "$ LINK/EXE=OBJLIB:X.EXE/MAP=OBJLIB:X.MAP -"DEMIT " OBJLIB:OBJLIB.OLB/INCLUDE=C,OBJLIB:OBJLIB.OLB/LIBRARY"EMIT "$ DEASSIGN OBJLIB"$ VDE-VDEä CREATE SCRIPT/LINK=X.EXE [MYDIR]SCRIPT_CH%VDE-I-SCRPADDED, script from file DEV$:[MYDIR]SCRIPT_LINK_X.VDESCRIPT;2 added to the database/ script to link module [CODE]X.EXE (segment 10)>%VDE-I-COMMIT, database transaction has successfully committed VDEä SHOW SCRIPT/TEXT/LINK=X.EXE.Script to link module [CODE]X.EXE (segment 10) Text of script:J 1: ! script to generate the DCL commands needed to link module X.EXE. 2: ! 3: EMIT "$ SET VERIFY"/ 4: EMIT "$ DEFINE OBJLIB ", $DIR(OBJ,CODE): 5: EMIT "$ LINK/EXE=OBJLIB:X.EXE/MAP=OBJLIB:X.MAP -"L 6: EMIT " OBJLIB:OBJLIB.OLB/INCLUDE=C,OBJLIB:OBJLIB.OLB/LIBRARY" 7: EMIT "$ DEASSIGN OBJLIB" VDEä |
6FThis example displays the script file SCRIPT_LINK_X.VDESCRIPT to show Ethe text of the script. The script consists of two comment lines and Gfive EMIT commands. The EXIT command is omitted in this case. The user <then enters VDE and uses the CREATE SCRIPT command to enter 6the script into the VDE database. The /LINK qualifier Dspecifies that the script links module X.EXE in the current default Hfacility, facility CODE. By default, the script's segment number is 10. BFinally, the SHOW SCRIPT command shows that the script can now be %displayed directly from the database.
#3 |
---|
9VDEä CREATE SCRIPT/NEW_STREAM=* SCRIPT_NEW_STRM.VDESCRIPTJ%VDE-I-SCRPADDED, script from file DEV$:[MYDIR]SCRIPT_NEW_STRM.VDESCRIPT;3 added to the database8 script to create new stream for facility * (segment 10)>%VDE-I-COMMIT, database transaction has successfully committed"VDEä SHOW SCRIPT/TEXT/NEW_STREAM=*7Script to create new stream for facility * (segment 10) Text of script:? 1: ! VDE script to populate the directories for a facility' 2: ! when a new stream is created. 3: !A 4: EMIT "$ DEFINE/NOLOG OLDOBJ ", $DIR(OBJ,%CURRENT,%PARENT)B 5: EMIT "$ DEFINE/NOLOG NEWOBJ ", $DIR(OBJ,%CURRENT,%CURRENT)* 6: EMIT "$ COPY OLDOBJ:*.OLB NEWOBJ:"9 7: EMIT "$ COPY ",$DIR(SRC,%CURRENT,%PARENT),"*.H -"2 8: EMIT " ",$DIR(SRC,%CURRENT,%CURRENT) 9: EXIT VDEä |
6GThis example creates a NEW_STREAM script that will be executed for all Gfacilities when a new development stream is created. The CREATE SCRIPT Ccommand creates the script, and the SHOW SCRIPT command fetchs and Bdisplays the contents of the script from the database. The script Dgenerates DCL commands to copy all object libraries from the parent Dstream's object directory to the current stream's object directory. H(The "current" stream is the new stream being created in this Dcase.) The script also copies all .H files from the parent stream's Gsource directory for the facility to the new stream's source directory for the facility.
#4 |
---|
AVDEä CREATE SCRIPT/INSERT_GENERATION=[*]*.* [MYDIR]SCRIPT_INS_GENO%VDE-I-SCRPADDED, script from file DEV$:[MYDIR]SCRIPT_INS_GEN.VDESCRIPT;4 added to the database; script to insert generation for module [*]*.* (segment 10)>%VDE-I-COMMIT, database transaction has successfully committedVDEä.VDEä SHOW SCRIPT/TEXT/INSERT_GENERATION=[*]*.*:Script to insert generation for module [*]*.* (segment 10) Text of script:H 1: ! Script for the INSERT GENERATION command. This script fetchesH 2: ! out a clear copy of the generation just inserted into a streamD 3: ! in order to keep the stream's source directory up-to-date. 4: !3 5: FETCH $FACMODTYP, "/LOG/OUTPUT=", $DIR(SRC)* 6: EMIT "$ PURGE ", $DIR(SRC),$MODTYP VDEä |
BThis example defines a script to be executed each time the INSERT HGENERATION command is performed for any module. The SHOW SCRIPT command Edisplays the text of the script. The script contains a FETCH command Hthat fetches the just inserted generation into the SRC subdirectory for >the affected stream and facility. This operation maintains an Gup-to-date copy of the source file in that directory. Because the /LOG =qualifier is generated for the FETCH command, VDE will print Dan informational log message as the module is fetched during script Eexecution. The script also contains an EMIT command that generates a ;PURGE command to be performed on the file just fetched out.
7Creates a new reservation session in the VDE database. =Sessions are used to group reservations in the VDE database. FAttributes of a session include the session name name and the session remark string.
9CREATE SESSION session-name [, session-name...]
session-name
EThe name of the new session to be created. This name can be up to 39 0characters long and must follow VDE name syntax.
HWhen a user reserves one or more modules with the /SESSION qualifier to ;the RESERVE command, VDE creates a reservation session and Emakes the module reservations members of that session. A reservation Csession is thus a set of module reservations that belong together. @Additional module reservations can be added to the session with Fadditional RESERVE commands. When the modules are later replaced into 8the VDE library, the user can specify the session to be Greplaced (using the /SESSION qualifier to the REPLACE command) instead Fof listing all the modules individually. A session thus makes it easy Ato replace a set of related module reservations as a single unit.BAlthough reservation sessions are normally created by the RESERVE Ccommand, you can create a session directly with the CREATE SESSION Ecommand. This session initially contains no module reservations. You Bcan later add module reservations to the session with the RESERVE Fcommand, using the /SESSION qualifier to specify the session name. To @remove an existing non-empty session, use the UNRESERVE/SESSION Ecommand. To remove an existing empty session, use the CANCEL SESSION command.
/LOG (default)
/NOLOG
EControls whether log messages are printed after the new sessions are Fcreated. The /LOG qualifier causes the messages to be printed and the F/NOLOG qualifier suppresses them. The messages indicate that each new Greservation session has been created and that the database transaction has successfully committed./REMARK="string"
HSpecifies a remark string to be stored for the new reservation session. FThe quoted remark string, which can be up to 132 characters long, may Ccontain any explanatory remark about the new session that you want stored in the VDE database.EAlthough this qualifier is required, you can specify an empty remark 9string. If you do not specify the /REMARK qualifier, VDE prompts you for a remark string.
6
#1 |
---|
BVDEä CREATE SESSION FIX-SORT-BUG /REMARK="Fix bug in sort routine";%VDE-I-SESADDED, session FIX-SORT-BUG added to the database>%VDE-I-COMMIT, database transaction has successfully committedVDEä?VDEä RESERVE [SYS]SORT.PAS /SESSION=FIX-SORT-BUG "Fix sort bug"D%VDE-I-FETCHED, generation [SYS]SORT.PAS;4(2A2) fetched from library4%VDE-I-OUTFILE, output file is DEV$:[MYDIR]SORT.PAS;Q%VDE-I-RESERVED, module generation [SYS]SORT.PAS;4(2A2) reserved from stream MAIN>%VDE-I-COMMIT, database transaction has successfully committedVDEä |
GThis example creates a new session called FIX--SORT--BUG and specifies Ha remark string for it. The RESERVE command then adds a reservation for $module [SYS]SORT.PAS to the session.
PreviousX | Next[ | Contents] | Index |