🔥码云GVP开源项目 12k star Uniapp+ElementUI 功能强大 支持多语言、二开方便! 广告
# F.7 GlobMapper The `GlobMapper` works like the `copy` command in DOS: ``` <copy todir="/tmp"> <mapper type="glob" from="*.php" to="*.php.bak"/> <fileset refid="someid" /> </copy> ``` This will change the extension of all files matching the pattern `*.php` to `.php.bak`. Table F.7:聽 The globmapper mapper can take the following extra attributes. NameTypeDescriptionDefaultRequired`handledirsep``String`If this is specified, the mapper will ignore the difference between the normal directory separator characters - \\ and /. This attribute is useful for cross-platform build files.falseNo`casesensitive``Boolean`If this is false, the mapper will ignore case when matching the glob pattern.trueNo F.7.1 Examples `<mapper type="glob" from="*txt" to="*txt.bak"/>`Applying the mapper, you will get the following results from the following filenames: Table F.8:聽Result of mapping FromTo`test.txt``test.txt.bak``./foo/bar/test.txt``./foo/bar/test.txt.bak``mytxt``mytxt.bak``SomeClass.php``ignored`, SomeClass.php