in reply to sed style file parse from command-line
$perl -pi'orig_*' -e 's/I/A/ if /^THIS/' fileA [download]
see: perldoc perlrun about -p, -i, -e switches