home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Club Amiga de Montreal - CAM
/
CAM_CD_1.iso
/
files
/
255.lha
/
RexxArpLib_v2.2
/
rexx
/
alter.rexx
next >
Wrap
OS/2 REXX Batch file
|
1989-06-13
|
751b
|
41 lines
/** alter.rexx
*
* This function edits all the files containing one or more occurrences
* of a search string and sets the editor in searc/replace mode using a
* replacement string.
*
**/
parse arg fn ss rs .
options prompt "Next? "
if rs = "" then do
say "Usage: alter <wildcards> <search string> <replace string>"
exit
end
if ~show('l','rexxarplib.library') then addrexxlib
'search 'fn' 'ss' quiet | execio stem files.'
do i = 1 to files.0
if files.i = "" then leave
if i ~= 1 then do
parse pull yesno
if left(yesno, 1) = 'n' then do
say "Aborted"
exit
end
end
call setenv('Search', ss)
call setenv('Replace', rs)
'e 'files.i' startup alter.txed sticky'
end
say "Done"
exit