I want to get the file extension in Groovy with a regex, for let's say South.6987556.Input.csv.cop
.
http://www.regexplanet.com/advanced/java/index.html shows me that the second group would really contain the cop
extension. Which is what I want.
0: [0,27] South.6987556.Input.csv.cop
1: [0,23] South.6987556.Input.csv
2: [24,27] cop
I just don't understand why the result won't be
0: [0,27] South.6987556.Input.csv.cop
1: [0,23] South
2: [24,27] 6987556.Input.csv.cop
What should be the regex to get this kind of result?