I have the following hierarchy of files
+ - A
- a1.html
- a2.html
+ - B
+ - C
- c1.html
- c2.html
- b1.html
- b2.html
I want to add a <base> tag to all the files (using <replaceregexp> or anything similar) so that for the files one level deep it will be href="..", for two levels deep it will be href="../.." and so on.
What’s the fastest/easiest way to do it in Ant?
I ended up using a scripting language. Unfortunately there’s no task/mapper to do this.