npm-pkgbuild 15.3.20 → 15.3.22
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 +25 -25
- package/package.json +12 -12
- package/src/output/debian.mjs +3 -3
- package/src/output/packager.mjs +10 -3
- package/types/output/packager.d.mts +1 -1
- package/types/output/rpm.d.mts +1 -1
package/README.md
CHANGED
|
@@ -97,24 +97,24 @@ See [mf-hosting](https://www.npmjs.com/package/mf-hosting) or [mf-hosting-fronte
|
|
|
97
97
|
* [FileContentProvider](#filecontentprovider)
|
|
98
98
|
* [Parameters](#parameters-1)
|
|
99
99
|
* [name](#name)
|
|
100
|
+
* [NFTContentProvider](#nftcontentprovider)
|
|
101
|
+
* [Parameters](#parameters-2)
|
|
102
|
+
* [name](#name-1)
|
|
100
103
|
* [utf8StreamOptions](#utf8streamoptions)
|
|
101
104
|
* [Properties](#properties-1)
|
|
102
105
|
* [packageNameMapping](#packagenamemapping)
|
|
103
106
|
* [decodePassword](#decodepassword)
|
|
104
|
-
* [Parameters](#parameters-
|
|
107
|
+
* [Parameters](#parameters-3)
|
|
105
108
|
* [FunctionDecl](#functiondecl)
|
|
106
109
|
* [Properties](#properties-2)
|
|
107
110
|
* [extractFunctions](#extractfunctions)
|
|
108
|
-
* [Parameters](#parameters-3)
|
|
109
|
-
* [fieldProvider](#fieldprovider)
|
|
110
111
|
* [Parameters](#parameters-4)
|
|
111
|
-
* [
|
|
112
|
+
* [fieldProvider](#fieldprovider)
|
|
112
113
|
* [Parameters](#parameters-5)
|
|
113
|
-
* [
|
|
114
|
+
* [Expander](#expander)
|
|
114
115
|
* [Parameters](#parameters-6)
|
|
115
|
-
* [
|
|
116
|
+
* [copyEntries](#copyentries)
|
|
116
117
|
* [Parameters](#parameters-7)
|
|
117
|
-
* [name](#name-1)
|
|
118
118
|
* [NodeModulesContentProvider](#nodemodulescontentprovider)
|
|
119
119
|
* [Parameters](#parameters-8)
|
|
120
120
|
* [Properties](#properties-3)
|
|
@@ -210,6 +210,24 @@ Content provided form the file system.
|
|
|
210
210
|
|
|
211
211
|
Returns **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** name of the content provider
|
|
212
212
|
|
|
213
|
+
## NFTContentProvider
|
|
214
|
+
|
|
215
|
+
**Extends ContentProvider**
|
|
216
|
+
|
|
217
|
+
Content provided form the file system.
|
|
218
|
+
|
|
219
|
+
### Parameters
|
|
220
|
+
|
|
221
|
+
* `definitions` **([Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object) | [string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String))** 
|
|
222
|
+
|
|
223
|
+
* `definitions.pattern` **([string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String) | [Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)<[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)>)** 
|
|
224
|
+
* `definitions.base` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** base directory where to find the files
|
|
225
|
+
* `entryProperties`  
|
|
226
|
+
|
|
227
|
+
### name
|
|
228
|
+
|
|
229
|
+
Returns **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** name of the content provider
|
|
230
|
+
|
|
213
231
|
## utf8StreamOptions
|
|
214
232
|
|
|
215
233
|
Type: [Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object)
|
|
@@ -281,24 +299,6 @@ Destination paths a generated without leading '/' (as for entry names too).
|
|
|
281
299
|
* `destinationDirectory` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** 
|
|
282
300
|
* `expander` **[Expander](#expander)** (optional, default `v=>v`)
|
|
283
301
|
|
|
284
|
-
## NFTContentProvider
|
|
285
|
-
|
|
286
|
-
**Extends ContentProvider**
|
|
287
|
-
|
|
288
|
-
Content provided form the file system.
|
|
289
|
-
|
|
290
|
-
### Parameters
|
|
291
|
-
|
|
292
|
-
* `definitions` **([Object](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Object) | [string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String))** 
|
|
293
|
-
|
|
294
|
-
* `definitions.pattern` **([string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String) | [Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)<[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)>)** 
|
|
295
|
-
* `definitions.base` **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** base directory where to find the files
|
|
296
|
-
* `entryProperties`  
|
|
297
|
-
|
|
298
|
-
### name
|
|
299
|
-
|
|
300
|
-
Returns **[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)** name of the content provider
|
|
301
|
-
|
|
302
302
|
## NodeModulesContentProvider
|
|
303
303
|
|
|
304
304
|
**Extends ContentProvider**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "npm-pkgbuild",
|
|
3
|
-
"version": "15.3.
|
|
3
|
+
"version": "15.3.22",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public",
|
|
6
6
|
"provenance": true
|
|
@@ -51,38 +51,38 @@
|
|
|
51
51
|
"tsc:types": "tsc -d --allowJs --declarationDir dist --emitDeclarationOnly ./src/extract-from-package.mjs"
|
|
52
52
|
},
|
|
53
53
|
"dependencies": {
|
|
54
|
-
"@npmcli/arborist": "^7.5.
|
|
55
|
-
"@vercel/nft": "^0.27.
|
|
54
|
+
"@npmcli/arborist": "^7.5.3",
|
|
55
|
+
"@vercel/nft": "^0.27.2",
|
|
56
56
|
"aggregate-async-iterator": "^1.2.1",
|
|
57
57
|
"commander": "^12.1.0",
|
|
58
58
|
"compare-versions": "^6.1.0",
|
|
59
|
-
"content-entry": "^11.0.
|
|
59
|
+
"content-entry": "^11.0.1",
|
|
60
60
|
"content-entry-filesystem": "^6.0.0",
|
|
61
61
|
"content-entry-transform": "^1.4.29",
|
|
62
|
-
"execa": "^9.
|
|
62
|
+
"execa": "^9.3.0",
|
|
63
63
|
"expression-expander": "^7.2.5",
|
|
64
64
|
"globby": "^14.0.1",
|
|
65
65
|
"ini": "^4.1.3",
|
|
66
66
|
"iterable-string-interceptor": "^3.0.0",
|
|
67
67
|
"key-value-transformer": "^3.2.3",
|
|
68
|
-
"npm-package-walker": "^7.0.
|
|
68
|
+
"npm-package-walker": "^7.0.2",
|
|
69
69
|
"npm-packlist": "^8.0.2",
|
|
70
70
|
"pacote": "^18.0.6",
|
|
71
71
|
"pkg-dir": "^8.0.0",
|
|
72
72
|
"tar-stream": "^3.1.7",
|
|
73
|
-
"uti": "^8.6.
|
|
73
|
+
"uti": "^8.6.1"
|
|
74
74
|
},
|
|
75
75
|
"devDependencies": {
|
|
76
|
-
"@types/node": "^20.
|
|
76
|
+
"@types/node": "^20.14.9",
|
|
77
77
|
"ava": "^6.1.3",
|
|
78
|
-
"c8": "^
|
|
78
|
+
"c8": "^10.1.2",
|
|
79
79
|
"documentation": "^14.0.3",
|
|
80
|
-
"semantic-release": "^
|
|
80
|
+
"semantic-release": "^24.0.0",
|
|
81
81
|
"stream-buffers": "^3.0.2",
|
|
82
|
-
"typescript": "^5.
|
|
82
|
+
"typescript": "^5.5.2"
|
|
83
83
|
},
|
|
84
84
|
"engines": {
|
|
85
|
-
"node": ">=20.
|
|
85
|
+
"node": ">=20.15.0",
|
|
86
86
|
"bun": ">=1.1"
|
|
87
87
|
},
|
|
88
88
|
"repository": {
|
package/src/output/debian.mjs
CHANGED
|
@@ -85,8 +85,8 @@ export class DEBIAN extends Packager {
|
|
|
85
85
|
if (name) {
|
|
86
86
|
yield new StringContentEntry(
|
|
87
87
|
name,
|
|
88
|
-
f.body.
|
|
89
|
-
/\{\{(\w+)\}\}/
|
|
88
|
+
f.body.replaceAll(
|
|
89
|
+
/\{\{(\w+)\}\}/mg,
|
|
90
90
|
(match, key, offset, string) =>
|
|
91
91
|
properties[key] || "{{" + key + "}}"
|
|
92
92
|
)
|
|
@@ -154,7 +154,7 @@ export class DEBIAN extends Packager {
|
|
|
154
154
|
|
|
155
155
|
if (options.verbose) {
|
|
156
156
|
console.log(
|
|
157
|
-
await readFile(join(staging, debianControlName),
|
|
157
|
+
await readFile(join(staging, debianControlName), "utf8")
|
|
158
158
|
);
|
|
159
159
|
}
|
|
160
160
|
|
package/src/output/packager.mjs
CHANGED
|
@@ -52,7 +52,7 @@ export class Packager {
|
|
|
52
52
|
* @param {Object} properties
|
|
53
53
|
*/
|
|
54
54
|
constructor(properties) {
|
|
55
|
-
this.#properties = { ...properties };
|
|
55
|
+
this.#properties = { ...properties, type: this.constructor.name };
|
|
56
56
|
}
|
|
57
57
|
|
|
58
58
|
get fileNameExtension() {
|
|
@@ -134,7 +134,7 @@ export class Packager {
|
|
|
134
134
|
|
|
135
135
|
if (publishingDetail) {
|
|
136
136
|
out.destination =
|
|
137
|
-
|
|
137
|
+
publishingDetail.scheme === "file:" ? publishingDetail.url : tmpdir;
|
|
138
138
|
await mkdir(out.destination, mdo);
|
|
139
139
|
}
|
|
140
140
|
|
|
@@ -151,7 +151,14 @@ export class Packager {
|
|
|
151
151
|
* @param {function(string):string} expander
|
|
152
152
|
* @return {Promise<string>} identifier of the resulting package
|
|
153
153
|
*/
|
|
154
|
-
async create(
|
|
154
|
+
async create(
|
|
155
|
+
sources,
|
|
156
|
+
transformer,
|
|
157
|
+
dependencies,
|
|
158
|
+
publishingDetails,
|
|
159
|
+
options,
|
|
160
|
+
expander
|
|
161
|
+
) {
|
|
155
162
|
throw new Error("not implemented");
|
|
156
163
|
}
|
|
157
164
|
|
|
@@ -66,7 +66,7 @@ export class Packager {
|
|
|
66
66
|
publish(artifact: any, publishingDetails: any, properties: any, logger: any): Promise<void>;
|
|
67
67
|
#private;
|
|
68
68
|
}
|
|
69
|
-
export type PublishingDetail = import(
|
|
69
|
+
export type PublishingDetail = import("../publish.mjs").PublishingDetail;
|
|
70
70
|
export type Field = {
|
|
71
71
|
/**
|
|
72
72
|
* interchangeable field name
|
package/types/output/rpm.d.mts
CHANGED
|
@@ -87,5 +87,5 @@ export class RPM extends Packager {
|
|
|
87
87
|
get packageFileName(): string;
|
|
88
88
|
create(sources: any, transformer: any, dependencies: any, publishingDetails: any, options: any, expander: any): Promise<string>;
|
|
89
89
|
}
|
|
90
|
-
export type PublishingDetail = import(
|
|
90
|
+
export type PublishingDetail = import("../publish.mjs").PublishingDetail;
|
|
91
91
|
import { Packager } from "./packager.mjs";
|