server-up-ndot 1.2.0-beta.3 → 1.2.1
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "server-up-ndot",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.1",
|
|
4
4
|
"description": "server toolkit",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"bin": {
|
|
@@ -52,7 +52,8 @@
|
|
|
52
52
|
"validator": "*",
|
|
53
53
|
"ws": "*",
|
|
54
54
|
"xml2js": "*",
|
|
55
|
-
"yargs": "*"
|
|
55
|
+
"yargs": "*",
|
|
56
|
+
"dotenv": "*"
|
|
56
57
|
},
|
|
57
58
|
"keywords": [],
|
|
58
59
|
"author": "",
|
package/readme.md
CHANGED
|
@@ -1,12 +1,3 @@
|
|
|
1
|
-
⚠️ beta.1 version.
|
|
2
|
-
May contain bugs. Possibly many.
|
|
3
|
-
|
|
4
|
-
If you find one, don't panic.
|
|
5
|
-
If you panic, your computer might also kernel panic!
|
|
6
|
-
|
|
7
|
-
At the same time, my nickname "segfaultandsegmentationfault"
|
|
8
|
-
may be activated.
|
|
9
|
-
|
|
10
1
|
# server-up-ndot
|
|
11
2
|
|
|
12
3
|
Simple server generator and auto library install for Node.js.
|
|
@@ -34,6 +25,13 @@ npx server-up-ndot create myserver
|
|
|
34
25
|
|
|
35
26
|
## Patch Notes
|
|
36
27
|
|
|
28
|
+
### 1.2.1
|
|
29
|
+
- new folder "public"
|
|
30
|
+
|
|
31
|
+
### 1.2.0
|
|
32
|
+
- This is now official release!
|
|
33
|
+
- bug patch
|
|
34
|
+
|
|
37
35
|
### 1.2.0-beta.3(pre-release)
|
|
38
36
|
- the new .env details!
|
|
39
37
|
- html path
|
package/templates/basic/.env
CHANGED
package/templates/basic/app.js
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
const express = require('express');
|
|
2
2
|
const cors = require('cors');
|
|
3
3
|
const net = require('net');
|
|
4
|
+
const path = require('path');
|
|
4
5
|
require('dotenv').config();
|
|
5
6
|
|
|
6
7
|
const app = express();
|
|
7
8
|
const startPort = process.env.PORT || 3000;
|
|
8
9
|
const msg = process.env.MSG_ROOT || "segfaultandsegmentationfault";
|
|
9
|
-
const html = process.env.HTML_FILE || "nonehtml.html"
|
|
10
|
+
const html = process.env.HTML_FILE || "./public/nonehtml.html"
|
|
10
11
|
app.use(cors());
|
|
11
12
|
app.use(express.json());
|
|
12
13
|
|
|
@@ -17,7 +18,7 @@ app.get('/', (req, res) => {
|
|
|
17
18
|
|
|
18
19
|
//html
|
|
19
20
|
app.get('/html', (req, res) => {
|
|
20
|
-
res.
|
|
21
|
+
res.sendFile(path.join(__dirname, `${html}`));
|
|
21
22
|
});
|
|
22
23
|
|
|
23
24
|
// POST
|
|
File without changes
|
|
File without changes
|