Strange Copy+ReplaceTokens behavior

(steve) #1

I can only assume that ReplaceTokens is persistently cached somewhere.

The situation… We previously had a module named ‘hibernate-entitymanager’ in a multi-project build. That module is being folded into another model named ‘hibernate-core’.

The hibernate-entitymanager build had a Copy task defined with a filter to apply token replacement. One of those replacements is the build dir for the project. So we copied this task definition over to hibernate-core. However, when this task is triggered in hibernate-core, the replacement still uses hibernate-entitymanager. We have made triple sure that we are not referencing “hibernate-entitymanager” in the build. The replacement is defined using buildDir.absolutePath. Obviously since the task is now in the hibernate-core project buildDir ought to refer to its build/output dir.

(steve) #2

interestngly it went away as soon as we deleted the hibernate-entitymanager directory. Even though it was empty… Weird…