-
gulp-awspublish是一款用于将文件上传至亚马逊S3的gulp插件
资源介绍
gulp-aws发布
awspublish插件
用法
首先,将gulp-awspublish安装为开发依赖项:
npm install --save-dev gulp-awspublish
然后,将其添加到您的gulpfile.js :
var awspublish = require ( "gulp-awspublish" ) ;
gulp . task ( "publish" , function ( ) {
// create a new publisher using S3 options
// http://docs.aws.amazon.com/AWSJavaScriptSDK/latest/AWS/S3.html#constructor-property
var publisher = awspublish . create (
{
region : "your-region-id" ,
params : {
Bucket : "..."
}
} ,
{
cache