grunt-aws-lambda
Advanced tools
Comparing version 0.7.0 to 0.8.0
@@ -65,3 +65,4 @@ /* | ||
include_time: false, | ||
package_folder: 'test/fixtures/package_custom' | ||
package_folder: 'test/fixtures/package_custom', | ||
include_files: ['custom.json'] | ||
} | ||
@@ -68,0 +69,0 @@ } |
{ | ||
"name": "grunt-aws-lambda", | ||
"description": "A grunt plugin to help develop AWS Lambda functions.", | ||
"version": "0.7.0", | ||
"version": "0.8.0", | ||
"homepage": "https://github.com/Tim-B/grunt-aws-lambda", | ||
@@ -6,0 +6,0 @@ "author": { |
@@ -194,2 +194,8 @@ # grunt-aws-lambda | ||
##### options.include_files | ||
Type: `Array` | ||
Default value: `[]` | ||
List of files to explicitly include in the package, even if they would be ignored by NPM | ||
##### options.include_time | ||
@@ -492,1 +498,5 @@ Type: `Boolean` | ||
### 0.8.0 | ||
* Adding `include_files` option to package - [pull request by dhleong](https://github.com/Tim-B/grunt-aws-lambda/pull/19) | ||
@@ -31,3 +31,4 @@ /* | ||
'include_time': true, | ||
'package_folder': './' | ||
'package_folder': './', | ||
'include_files': [] | ||
}); | ||
@@ -95,2 +96,13 @@ | ||
if (options.include_files.length) { | ||
zipArchive.bulk([ | ||
{ | ||
src: options.include_files, | ||
dot: true, | ||
expand: true, | ||
cwd: options.package_folder | ||
} | ||
]); | ||
} | ||
zipArchive.finalize(); | ||
@@ -97,0 +109,0 @@ |
@@ -62,3 +62,3 @@ 'use strict'; | ||
custom_options: function (test) { | ||
test.expect(5); | ||
test.expect(6); | ||
var zip = new AdmZip("tmp/dist/another-lambda-function_0-0-1_latest.zip"); | ||
@@ -68,2 +68,3 @@ var zipEntries = zip.getEntries(); | ||
var required = [ | ||
'custom.json', | ||
'index.js', | ||
@@ -84,2 +85,3 @@ 'package.json', | ||
} | ||
}; |
Sorry, the diff of this file is not supported yet
35695
26
504
501