kr-shell / serverless-plop-cli

This article covers using the Plop framework to create a CLI which can auto generate our scaffolded serverless code; with code examples written in TypeScript and the AWS CDK.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Serverless Plop CLI

This article covers using the Plop framework to create a basic CLI which can auto generate our scaffolded serverless code using the clean code lightweight approach; with code examples written in TypeScript and the AWS CDK.

NOTE: This is a basic example of the CLI to show the templating approach with Plop - this is not production ready.

image

The article can be found here: https://blog.serverlessadvocate.com/using-plop-to-improve-our-serverless-developer-experience-22634147ebb1

Getting started

Let's start by installing this local package as if it is a npm package:

  1. change directory into the advocate-cli folder
cd into advocate-cli
  1. Install the dependencies:
npm i
  1. build the CLI and link this in dev mode like a global package
npm run build && npm run link

To run the solution please look at the steps in the article linked above.

** The information and code provided are my own and I accept no responsibility on the use of the information. **

About

This article covers using the Plop framework to create a CLI which can auto generate our scaffolded serverless code; with code examples written in TypeScript and the AWS CDK.


Languages

Language:TypeScript 60.6%Language:Handlebars 33.0%Language:JavaScript 6.4%