2.0.1 • Published 10 years ago
generator-lambda v2.0.1
generator-lambda 
AWS Lambda function generator.
What it can do:
- Lambda function create/update/delete wrap.
- Connecting lambda to inputed S3 bucket with selected event
- Test code locally
- Provide test json in test directory, json files are same as the provide at the Lambda online test page. You can append or edit it definitely.
Getting Started
Install and use generator
# install generator
npm install -g generator-lambda
# run
yo lambdaWork with the generated lambda function
Structure
├── Makefile
├── index.js
├── package.json
├── test
│ ├── ctx.js
│ ├── helloworld.json
│ ├── s3_delete.json
│ ├── s3_put.json
│ └── sns.json
└── test.jsindex.jsFunction code here, please do not change the file name, if you want, please change theMakefiletoo.MakefileWrap of aws cli, provide function create/update/deletepackage.jsonAny extra dependency here, usenpm i --savefor reuse.test.jsUsenode test.jsto test locally, feel free to edit the file as you want
Makefile integrated
# create function, and connect it with inputed s3 bucket
make create
# update function code
make
# run code locally
make test
# delete function
make deleteLicense
MIT