Chgset.Cmd:
parm filesetParm="@" purge fileset,temp listfile !filesetParm > fileset,6 purge chgcmds,temp :beginfile chgcmds :parm filename :comment :/t !filename,yes :comment Insert all your edit commands in here :comment be sure to start each line with a colon :endfile /t fileset /d 1/3 /d "~" (p) /c 1 "chgcmds " @ /u *The command file creates a temporary command file that will perform the actual edit operations. The version above does not contain any so you have to customize it with the things you want to do. All you have to do is insert the commands between the last :comment line and the :endfile. We recommend that you do not insert a Keep command immediately. Run it a few times without Keep to make sure it makes the appropriate changes. Once you have confirmed that everything works as expected, insert a Keep ,IfDirty to save the changes, if any.
:beginfile chgcmds :parm filename :comment :/t !filename,yes :comment Insert all your edit commands in here :comment be sure to start each line with a colon :/d "~" (pattern) :/k ,ifdirty :endfileTo run it, enter:
chgsetTo change all occurrences of the word Display to the word Print in files whose names start with T, the command file needs to be modified like this:
:beginfile chgcmds :parm filename :comment :/t !filename,yes :comment Insert all your edit commands in here :comment be sure to start each line with a colon :/c "Display" (s) "Print" @ :/k ,ifdirty :endfileTo run it, enter:
chgset t@To perform the same changes in all MPE and Posix files, enter:
chgset ./@
See also "how to list lines in a fileset".
[François Desrochers]