【发布时间】:2014-10-19 10:43:53
【问题描述】:
我在 Gulp 中有以下数组:
var imageFiles = {
'bootstrap-fileinput': 'bower/bootstrap-fileinput/dist/img/*',
'some-other-thing': 'bower/some-other-thing/dist/img/*'
};
如果需要,我可以重组,只要该前缀有前缀和路径即可。
如何让 gulp 将我的图像复制到我想要的单个文件夹中,但在每个文件夹前面加上数组中的前缀?意思是:
bower/bootstrap-fileinput/dist/img/arrow.jpg => /images/bootstrap-fileinput_arrow.jpg
凉亭/其他东西/dist/img/arrow.jpg => /images/some-other-thing_arrow.jpg
27.08.14: 我是否理解正确,我描述的任务不能仅使用一根管道来完成?正如我所见,在@Doodlebot 提供的解决方案中,每个文件都是独立且按顺序传输的。
【问题讨论】:
标签: gulp gulp-rename