if some condition from file one read file two into string do regexp string replace write file two to a file end if