L
laredotornado
Hi,
I'm not so familiar with perl but it seems this is the kind of task it
is suited for. I have a file of numbers, one number per line. Then I
have a template file that contains ...
public void testXMatchValid_UCASE() throws java.lang.Exception {
_testMatchUpperCase(X);
}
public void testXMatchValid_lcase() throws java.lang.Exception {
_testMatchLowerCase(X);
}
I want the final file to have each number replace the "X" in the
template file and the template would repeat for the number of lines in
the numbers file. So if the numbers file contained
10
20
the resulting output file would contain
public void test10MatchValid_UCASE() throws java.lang.Exception {
_testMatchUpperCase(10);
}
public void test10MatchValid_lcase() throws java.lang.Exception {
_testMatchLowerCase(10);
}
public void test20MatchValid_UCASE() throws java.lang.Exception {
_testMatchUpperCase(20);
}
public void test20MatchValid_lcase() throws java.lang.Exception {
_testMatchLowerCase(20);
}
HOw would I pull this off using perl? Thanks, - Dave
I'm not so familiar with perl but it seems this is the kind of task it
is suited for. I have a file of numbers, one number per line. Then I
have a template file that contains ...
public void testXMatchValid_UCASE() throws java.lang.Exception {
_testMatchUpperCase(X);
}
public void testXMatchValid_lcase() throws java.lang.Exception {
_testMatchLowerCase(X);
}
I want the final file to have each number replace the "X" in the
template file and the template would repeat for the number of lines in
the numbers file. So if the numbers file contained
10
20
the resulting output file would contain
public void test10MatchValid_UCASE() throws java.lang.Exception {
_testMatchUpperCase(10);
}
public void test10MatchValid_lcase() throws java.lang.Exception {
_testMatchLowerCase(10);
}
public void test20MatchValid_UCASE() throws java.lang.Exception {
_testMatchUpperCase(20);
}
public void test20MatchValid_lcase() throws java.lang.Exception {
_testMatchLowerCase(20);
}
HOw would I pull this off using perl? Thanks, - Dave