I got a textfile like this
"
set [$APPL_CODE] = SLP
set [$MYSQL_SERVER] = ecarl0.bc
set [$MYSQL_PORT] = 304
set [$DB_DISK_QUOTA] = 00Mb
in [$MYSQL_server]
logon with ssh e.g. from ecar0o.bc with ssh mysql@[$MYSQL_SERVER]
(password is the same as for oracle-user)
verify that the new filesystems are owned by mysql:mysql :
/users/application/mydb[$MYSQL_PORT]
"
off course with a lot more codes and text.
I want to replace every occurence of text between [] with the value assigned to it in the "set " line.
I created a macro like this
"
InsertMode
ColumnModeOff
HexOff
UnixReOff
Find RegExp "set ^(^[^$MYSQL_SERVER^]^) = ^(*^) ^p"
Find RegExp "^1"
Replace All "^2"
Find RegExp "set ^(^[^$MYSQL_PORT^]^) = ^(*^) ^p"
Find RegExp "^1"
Replace All "^2"
Find RegExp "set ^(^[^$WEB_SERVER^]^) = ^(*^) ^p"
Find RegExp "^1"
Replace All "^2"
"
but apparantly the second find where he looks for tagged expression 1 fails (although it exists)
Can someone help me out ?
"
set [$APPL_CODE] = SLP
set [$MYSQL_SERVER] = ecarl0.bc
set [$MYSQL_PORT] = 304
set [$DB_DISK_QUOTA] = 00Mb
in [$MYSQL_server]
logon with ssh e.g. from ecar0o.bc with ssh mysql@[$MYSQL_SERVER]
(password is the same as for oracle-user)
verify that the new filesystems are owned by mysql:mysql :
/users/application/mydb[$MYSQL_PORT]
"
off course with a lot more codes and text.
I want to replace every occurence of text between [] with the value assigned to it in the "set " line.
I created a macro like this
"
InsertMode
ColumnModeOff
HexOff
UnixReOff
Find RegExp "set ^(^[^$MYSQL_SERVER^]^) = ^(*^) ^p"
Find RegExp "^1"
Replace All "^2"
Find RegExp "set ^(^[^$MYSQL_PORT^]^) = ^(*^) ^p"
Find RegExp "^1"
Replace All "^2"
Find RegExp "set ^(^[^$WEB_SERVER^]^) = ^(*^) ^p"
Find RegExp "^1"
Replace All "^2"
"
but apparantly the second find where he looks for tagged expression 1 fails (although it exists)
Can someone help me out ?