Details
-
Fix
-
Status: Released (View Workflow)
-
Minor
-
Resolution: Fixed
-
2.8.0
-
None
Description
Current Situation
- YADE supports renaming files during transfer from a source system to a target system.
- The ReplaceWhat element expects a regular expression that matches the file name.
- If the regular expression is defined as .* (match the entire file name), the replacement is applied twice.
- As a result, the replaced file name is duplicated.
- Example:
- ReplaceWhat = .*
- ReplaceWith = XYZ
- Resulting file name: XYZXYZ
Desired Behavior
- When ReplaceWhat = .* is used, the file name should be substituted exactly once.
- Example above - the resulting file name should be: XYZ
Workaround
- Use a capturing group to ensure a single replacement:
ReplaceWhat = (.*)
Patch
- Use the cumulative patch provided with
YADE-637.