nodebasecli
Version:
Cli to create modules for nodebase
98 lines (59 loc) • 1.48 kB
Markdown
# nodebase-cli
This is a package developed to helps you to create industry standard code structure
### To install cli
```bash
npm i -g nodebasecli
```
### Available Cli commands
This package comes with cli commands to create controller, model, middleware and mail
#### Create Controller
This cli command will create controller
```bash
nodebase make:controller UserController
```
#### Create Model
This cli command will create model
```bash
nodebase make:model UserDetail
```
#### Create Mail
This cli command will create mail
```bash
nodebase make:mail OrderMail
```
#### Create Middleware
This cli command will create middleware
```bash
nodebase make:middleware KeyValidateMiddleware
```
#### Install socket server
This cli command will install and set socket server to you server file
```bash
nodebase app:install socket
```
copy the code below to server file
```
import { Server } from 'socket.io';
import { SocketController } from './app/controllers/socket/socketController.js';
```
#### Add Aws Services
#### Add Aws Services
This cli command will add aws services to your project
The services you can add are:
- sqs
- sns
- ses
- sts
- s3
```bash
nodebase app:add sqs
OR
nodebase app:add sns
OR
nodebase app:add ses
OR
nodebase app:add sts
OR
nodebase app:add s3
```
The service files will be createn in the aws folder inside utils