express-todo 1.1.1 → 1.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +123 -0
- package/bin/cli.js +1 -1
- package/bin/{v1/commands/express.js → v2/commands/simple.js} +5 -5
- package/bin/{v1 → v2}/core/resolveCommand.js +2 -2
- package/bin/{v1 → v2}/core/showUsage.js +5 -11
- package/package.json +1 -1
- /package/bin/{v1 → v2}/commands/exportCommands/express.js +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/steps/announce.js +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/steps/createProject.js +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/steps/locateDestination.js +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/steps/locateSource.js +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/.env +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/.env.local +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/.vscode/launch.json +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/Config/Schemas/BillsTable.json +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/Config/Schemas/ItemsTable.json +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/Config/Schemas/LedgerNames.json +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/Config/Schemas/StockItems.json +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/Config/api.json +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/Config/schema.json +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/Config/ui.json +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/Public/index.html +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/app.js +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/config.json +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/configLoader.js +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/package-lock.json +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/package.json +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/port.js +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/routes.js +0 -0
- /package/bin/{v1/commands/express → v2/commands/simple}/template/v7/server.js +0 -0
- /package/bin/{v1 → v2}/core/parseInput.js +0 -0
- /package/bin/{v1 → v2}/core/resolveFolderName.js +0 -0
- /package/bin/{v1 → v2}/start.js +0 -0
package/README.md
ADDED
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
# express-todo
|
|
2
|
+
|
|
3
|
+
Simple Express boilerplate generator for quickly starting Express applications.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Installation
|
|
8
|
+
|
|
9
|
+
## Using NPX (Recommended)
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
npx express-todo simple
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
# What It Does
|
|
18
|
+
|
|
19
|
+
The command:
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
npx express-todo simple
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
automatically creates a ready-to-use Express project with basic structure and starter configuration.
|
|
26
|
+
|
|
27
|
+
---
|
|
28
|
+
|
|
29
|
+
# Generated Structure
|
|
30
|
+
|
|
31
|
+
```txt
|
|
32
|
+
project-name/
|
|
33
|
+
│
|
|
34
|
+
├── .vscode/
|
|
35
|
+
├── Config/
|
|
36
|
+
├── Public/
|
|
37
|
+
├── .env
|
|
38
|
+
├── .env.local
|
|
39
|
+
├── app.js
|
|
40
|
+
├── config.json
|
|
41
|
+
├── configLoader.js
|
|
42
|
+
├── package.json
|
|
43
|
+
├── package-lock.json
|
|
44
|
+
├── port.js
|
|
45
|
+
├── routes.js
|
|
46
|
+
└── server.js
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
---
|
|
50
|
+
|
|
51
|
+
# Example
|
|
52
|
+
|
|
53
|
+
## Command
|
|
54
|
+
|
|
55
|
+
```bash
|
|
56
|
+
npx express-todo simple
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
## Output
|
|
60
|
+
|
|
61
|
+
```txt
|
|
62
|
+
[keshavsoft] Project created: your-project-name
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
---
|
|
66
|
+
|
|
67
|
+
# Quick Start
|
|
68
|
+
|
|
69
|
+
## Step 1
|
|
70
|
+
|
|
71
|
+
Create project:
|
|
72
|
+
|
|
73
|
+
```bash
|
|
74
|
+
npx express-todo simple
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
## Step 2
|
|
78
|
+
|
|
79
|
+
Move into project folder:
|
|
80
|
+
|
|
81
|
+
```bash
|
|
82
|
+
cd your-project-name
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
## Step 3
|
|
86
|
+
|
|
87
|
+
Install dependencies:
|
|
88
|
+
|
|
89
|
+
```bash
|
|
90
|
+
npm install
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
## Step 4
|
|
94
|
+
|
|
95
|
+
Start server:
|
|
96
|
+
|
|
97
|
+
```bash
|
|
98
|
+
npm start
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
---
|
|
102
|
+
|
|
103
|
+
# Why express-todo?
|
|
104
|
+
|
|
105
|
+
- Fast Express setup
|
|
106
|
+
- Clean starter structure
|
|
107
|
+
- Beginner friendly
|
|
108
|
+
- Reduces repetitive boilerplate work
|
|
109
|
+
- Simple command line usage
|
|
110
|
+
|
|
111
|
+
---
|
|
112
|
+
|
|
113
|
+
# Command Reference
|
|
114
|
+
|
|
115
|
+
```bash
|
|
116
|
+
npx express-todo simple
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
---
|
|
120
|
+
|
|
121
|
+
# License
|
|
122
|
+
|
|
123
|
+
MIT
|
package/bin/cli.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { locateSource } from "./
|
|
2
|
-
import { locateDestination } from "./
|
|
3
|
-
import { createProject } from "./
|
|
4
|
-
import { announce } from "./
|
|
1
|
+
import { locateSource } from "./simple/steps/locateSource.js";
|
|
2
|
+
import { locateDestination } from "./simple/steps/locateDestination.js";
|
|
3
|
+
import { createProject } from "./simple/steps/createProject.js";
|
|
4
|
+
import { announce } from "./simple/steps/announce.js";
|
|
5
5
|
|
|
6
6
|
import resolveFolderName from "../core/resolveFolderName.js";
|
|
7
7
|
|
|
8
|
-
export default ({
|
|
8
|
+
export default ({ folderName = "" }) => {
|
|
9
9
|
const resolvedFolderName = resolveFolderName({
|
|
10
10
|
name: folderName
|
|
11
11
|
});
|
|
@@ -22,24 +22,18 @@ export default function showUsage(version) {
|
|
|
22
22
|
const r = "\x1b[0m";
|
|
23
23
|
|
|
24
24
|
console.log(`
|
|
25
|
-
${c}🚀
|
|
25
|
+
${c}🚀 express-todo v${version}${r}
|
|
26
26
|
|
|
27
27
|
${y}Usage:${r}
|
|
28
|
-
${g}npx @keshavsoft/
|
|
28
|
+
${g}npx @keshavsoft/express-todo${r} <command> [options]
|
|
29
29
|
|
|
30
30
|
${y}Commands:${r}
|
|
31
|
-
${g}
|
|
32
|
-
${g}express${r} Initialize a new express project
|
|
33
|
-
${g}tally${r} Initialize a new tally project
|
|
34
|
-
${g}generate-samples${r} Generate sample schema files
|
|
35
|
-
${g}accounts${r} Initialize a new express project for simple accounting
|
|
31
|
+
${g}simple${r} Initialize a new simple express app
|
|
36
32
|
|
|
37
33
|
${y}Examples:${r}
|
|
38
|
-
${gray}npx @keshavsoft/
|
|
39
|
-
${gray}npx @keshavsoft/kschema-cli test users${r}
|
|
40
|
-
${gray}npx @keshavsoft/kschema-cli accounts${r}
|
|
34
|
+
${gray}npx @keshavsoft/express-todo simple${r}
|
|
41
35
|
|
|
42
36
|
${y}Tip:${r}
|
|
43
|
-
${gray}npm i -g @keshavsoft/
|
|
37
|
+
${gray}npm i -g @keshavsoft/express-todo${r}
|
|
44
38
|
`);
|
|
45
39
|
}
|
package/package.json
CHANGED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/bin/{v1/commands/express → v2/commands/simple}/template/v7/Config/Schemas/BillsTable.json
RENAMED
|
File without changes
|
/package/bin/{v1/commands/express → v2/commands/simple}/template/v7/Config/Schemas/ItemsTable.json
RENAMED
|
File without changes
|
/package/bin/{v1/commands/express → v2/commands/simple}/template/v7/Config/Schemas/LedgerNames.json
RENAMED
|
File without changes
|
/package/bin/{v1/commands/express → v2/commands/simple}/template/v7/Config/Schemas/StockItems.json
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/bin/{v1 → v2}/start.js
RENAMED
|
File without changes
|