expand option in grunt-contrib-copy
来源:互联网 发布:java简单工厂模式 编辑:程序博客网 时间:2024/05/28 18:42
Expand lets you specify whether you want to create the destination path in full (e.g: /path/missing1/missing2
), or only create the last directory when its parent exists (/path/existing/missing
).
http://stackoverflow.com/a/28900435/2177408
Since expand
is a part of Grunt, and not specific for grunt-contrib-copy, information about it can be found in Grunt's file configuration API:
Set
expand
totrue
to enable the following options:
cwd
Allsrc
matches are relative to (but don't include) this path.src
Pattern(s) to match, relative to thecwd
.dest
Destination path prefix.ext
Replace any existing extension with this value in generateddest
paths.extDot
Used to indicate where the period indicating the extension is located. Can take either'first'
(extension begins after the first period in the file name) or'last'
(extension begins after the last period), and is set by default to'first'
.flatten
Remove all path parts from generateddest
paths.rename
This function is called for each matchedsrc
file, (after extension renaming and flattening). Thedest
and matchedsrc
path are passed in, and this function must return a newdest
value. If the samedest
is returned more than once, eachsrc
which used it will be added to an array of sources for it.
Additionally it seems like dest
will always be considered to be a destination directory if setting expand
to true
.
Since expand
is a part of Grunt, and not specific for grunt-contrib-copy, information about it can be found in Grunt's file configuration API:
Set
expand
totrue
to enable the following options:
cwd
Allsrc
matches are relative to (but don't include) this path.src
Pattern(s) to match, relative to thecwd
.dest
Destination path prefix.ext
Replace any existing extension with this value in generateddest
paths.extDot
Used to indicate where the period indicating the extension is located. Can take either'first'
(extension begins after the first period in the file name) or'last'
(extension begins after the last period), and is set by default to'first'
.flatten
Remove all path parts from generateddest
paths.rename
This function is called for each matchedsrc
file, (after extension renaming and flattening). Thedest
and matchedsrc
path are passed in, and this function must return a newdest
value. If the samedest
is returned more than once, eachsrc
which used it will be added to an array of sources for it.
Additionally it seems like dest
will always be considered to be a destination directory if setting expand
to true
- expand option in grunt-contrib-copy
- Grunt Contrib Watch Example
- grunt的grunt-contrib-jshint插件使用
- grunt的grunt-contrib-concat插件使用
- win7安装grunt-contrib-qunit
- grunt-contrib-connect使用心得
- grunt-contrib-connect 中间件middleware属性
- grunt-contrib-uglify参数和使用
- npm install grunt-contrib-nodeunit --save-dev
- grunt-contrib-connect自动刷新html页面
- Nodemon和Grunt-Contrib-Watch: 有什么不同?
- 用 grunt-contrib-connect 构建实时预览开发环境
- 一步一步讲解如何安装并执行Grunt-contrib-watch插件
- 解决:grunt-contrib-jshint插件支持es6 syntax的问题
- Grunt in action
- grunt实践(target,option,task)
- Grunt中批量无损压缩图片插件--Grunt-contrib-imagemin
- Grunt中批量无损压缩图片插件--Grunt-contrib-imagemin
- 占位
- 占位
- 关于bmob后台云的使用心得
- Morris Traversal-常量空间下遍历二叉树
- 微软面试100题系列---求子数组的最大和
- expand option in grunt-contrib-copy
- strstrIII
- linearlib在ubuntu下配置python接口
- 微软面试100题系列---在二叉树中找出和为某一定值的所有路径
- js正则表达式语法
- tiles 框架在tiles.xml中配置路径后不显示内容,只显示一串文字问题
- formcheck.js
- 神器gist
- js动态创建表格