npm-pkgbuild 11.2.8 → 11.3.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": "npm-pkgbuild",
|
|
3
|
-
"version": "11.
|
|
3
|
+
"version": "11.3.1",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
"tar-stream": "^3.0.0"
|
|
61
61
|
},
|
|
62
62
|
"devDependencies": {
|
|
63
|
-
"ava": "^5.
|
|
63
|
+
"ava": "^5.2.0",
|
|
64
64
|
"c8": "^7.12.0",
|
|
65
65
|
"documentation": "^14.0.1",
|
|
66
66
|
"semantic-release": "^20.1.0",
|
|
@@ -229,6 +229,10 @@ export async function* extractFromPackage(options = {}, env = {}) {
|
|
|
229
229
|
properties.bugs = packageContent.bugs.url;
|
|
230
230
|
}
|
|
231
231
|
|
|
232
|
+
if (packageContent.bin) {
|
|
233
|
+
properties.entrypoints = packageContent.bin;
|
|
234
|
+
}
|
|
235
|
+
|
|
232
236
|
if (packageContent.contributors) {
|
|
233
237
|
properties.maintainer = packageContent.contributors.map(
|
|
234
238
|
c => `${c.name} <${c.email}>`
|
package/src/output/docker.mjs
CHANGED
|
@@ -43,10 +43,17 @@ export class DOCKER extends Packager {
|
|
|
43
43
|
);
|
|
44
44
|
|
|
45
45
|
async function* trailingLines() {
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
46
|
+
if (dependencies.node) {
|
|
47
|
+
yield `
|
|
48
|
+
FROM node:${dependencies.node.replace(/[>=]*/, "")}
|
|
49
49
|
`;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
if (options.entrypoints) {
|
|
53
|
+
yield `
|
|
54
|
+
ENTRYPOINT ["node", ${Object.values(options.entrypoints)[0]}]
|
|
55
|
+
`;
|
|
56
|
+
}
|
|
50
57
|
}
|
|
51
58
|
|
|
52
59
|
const fp = fieldProvider(properties, fields);
|