https://github.com/mirsahib/mern-skeleton-cli
:package: The mern CLI is a command-line interface tool that helps you to initialize, develop, and maintain your mern-skeleton project.
https://github.com/mirsahib/mern-skeleton-cli
Last synced: 7 months ago
JSON representation
:package: The mern CLI is a command-line interface tool that helps you to initialize, develop, and maintain your mern-skeleton project.
- Host: GitHub
- URL: https://github.com/mirsahib/mern-skeleton-cli
- Owner: mirsahib
- License: mit
- Created: 2021-09-10T05:45:44.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2021-12-24T13:55:50.000Z (almost 4 years ago)
- Last Synced: 2025-02-22T08:21:58.237Z (8 months ago)
- Language: JavaScript
- Homepage:
- Size: 50.8 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Description
The mern CLI is a command-line interface tool that helps you to initialize, develop, and maintain your mern-skeleton project.
# Installation
```bash
npm install -g mern-skeleton-cli
```# What is MERN-Skeleton
MERN-Skeleton a skeleton application with basic user CRUD and auth features - developed using React, Node, Express and MongoDB
[MERN-Skeleton Repo](https://github.com/shamahoque/mern-skeleton)# Command Structure
| Command | Option | Description
| --- | --- | --- |
| `mern create` | `-p,--project ` | Create a new project eg: `mern create -p myproject` |
| `mern create` | `-m,--model ` | Create a new model eg: `mern create -m company` |
| `mern create` | `-c,--controller ` | Create a new controller eg: `mern create -c company` |
| `mern create` | `-r,--router ` | Create a new routes eg: `mern create -r company` |Finally add the routes to `server/express.js`
```
import express from 'express'
import path from 'path'
import bodyParser from 'body-parser'
import cookieParser from 'cookie-parser'
import compress from 'compression'
import cors from 'cors'
import helmet from 'helmet'
import Template from './../template'
import userRoutes from './routes/user.routes'
import authRoutes from './routes/auth.routes'
import CompanyRoutes from './routes/company.routes' <=== import your routes here....
// mount routes
app.use('/', userRoutes)
app.use('/', authRoutes)
app.use('/',CompanyRoutes) <===== add your routes here....
export default app
```# Contribution
## Project Installation
```js
git clone https://github.com/mirsahib/mern-cli.git
cd mern-cli
npm i// add command
cd bin
node index //eg: node index create -p test```
If you want to **contribute** and make this project much better for other developer have a look at [Issues](https://github.com/mirsahib/mern-cli/issues).
If you created something awesome and want to contribute then feel free to open a [pull request](https://github.com/mirsahib/mern-cli/pulls).
# Special Thanks
[Shama Hoque](https://github.com/shamahoque) for creating MERN-Skeleton