Hello good people I am here again needing some help now I need to do a I script to compare two ".properties"..like
First file Name: dev.properties @v...@=test1 @v...@=test2 @v...@=test3 Secund fiel Name: prd.properties # comment @v...@=test1 @v...@=test1037 @v...@=test4 I need to compare these two files and so fail the build if then have some differences.. The files need to have the same numer of lines and each line must to have the same variable declared or to be a empty line or a comment. The variables declared in dev.properties must by declared ( in the same order ) in prd.properties and the variables in prd.properties must by in dev.properties, but the values of these variables can be different. So..the files should be like this to don't fail the build: dev.properties # comment @v...@=test1 @v...@=test2 @v...@=test3 @v...@=test4 prd.properties # comment @v...@=test1 @v...@=test1037 @v...@=test3 @v...@=test4123 That seens to be a idiot thing to do..but when I do a compare between these files I was trying to find something here http://ant.apache.org/manual/CoreTypes/filterchain.html#linecontainsregexp but I didn't find I way to compare line by line and I way to get the piece of each line before the "=" signal. the linecontainsregexp return all the line ..is there a "split method" in Ant ? Thanks all! -- Júlio Cesar Bueno Cotta Graduando em ciência da computação Universidade Federal de Viçosa
