makepack 1.5.11 → 1.5.13
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,8 +1,7 @@
|
|
|
1
1
|
|
|
2
2
|
export default async (info) => {
|
|
3
3
|
let pkgname = info.projectDirName
|
|
4
|
-
const content =
|
|
5
|
-
# ${pkgname}
|
|
4
|
+
const content = `# ${pkgname}
|
|
6
5
|
|
|
7
6
|
[](https://www.npmjs.com/package/${pkgname})
|
|
8
7
|
[](https://github.com/your-username/${pkgname}/blob/main/LICENSE)
|
|
@@ -14,13 +13,13 @@ A brief description of what your package does and its purpose.
|
|
|
14
13
|
|
|
15
14
|
\`\`\`sh
|
|
16
15
|
npm install ${pkgname}
|
|
17
|
-
|
|
16
|
+
\`\`\`
|
|
18
17
|
|
|
19
18
|
or with yarn:
|
|
20
19
|
|
|
21
20
|
\`\`\`sh
|
|
22
21
|
yarn add ${pkgname}
|
|
23
|
-
|
|
22
|
+
\`\`\`
|
|
24
23
|
|
|
25
24
|
## Usage
|
|
26
25
|
|
|
@@ -29,7 +28,7 @@ yarn add ${pkgname}
|
|
|
29
28
|
|
|
30
29
|
const result = feature("example");
|
|
31
30
|
console.log(result);
|
|
32
|
-
|
|
31
|
+
\`\`\`
|
|
33
32
|
|
|
34
33
|
## API
|
|
35
34
|
|
|
@@ -56,7 +55,7 @@ This project is licensed under the MIT License - see the [LICENSE](./LICENSE) fi
|
|
|
56
55
|
---
|
|
57
56
|
|
|
58
57
|
Feel free to modify this template based on your package's specific needs.
|
|
59
|
-
|
|
58
|
+
`;
|
|
60
59
|
return {
|
|
61
60
|
content,
|
|
62
61
|
filename: `readme.md`
|
|
@@ -68,6 +68,10 @@ const start = async (args) => {
|
|
|
68
68
|
}
|
|
69
69
|
});
|
|
70
70
|
|
|
71
|
+
app.use((_req, res) => {
|
|
72
|
+
res.status(500).send('Internal Server Error');
|
|
73
|
+
});
|
|
74
|
+
|
|
71
75
|
let server = app.listen(config.start.port, () => {
|
|
72
76
|
figlet("Makepack", function (err, data) {
|
|
73
77
|
if (err) {
|
|
@@ -82,11 +86,6 @@ const start = async (args) => {
|
|
|
82
86
|
logger.success(`Server is running on ${chalk.blue(chalk.underline(`http://localhost:${config.start.port}`))}`);
|
|
83
87
|
});
|
|
84
88
|
});
|
|
85
|
-
|
|
86
|
-
app.use((err, req, res) => {
|
|
87
|
-
logger.error(`Unhandled Error: ${err.message}`);
|
|
88
|
-
res.status(500).send('Internal Server Error');
|
|
89
|
-
});
|
|
90
89
|
}
|
|
91
90
|
|
|
92
91
|
export default start
|