我在 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
bower/some-other-thing/dist/img/arrow.jpg => /images/some-other-thing_arrow.jpg
27.08.14:我是否理解正确,我描述的任务不能仅使用一根管道来完成?如我所见,在@Doodlebot 提供的解决方案中,每个文件都是独立且按顺序传输的。