bililive-cli 3.16.0 → 3.16.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.
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var require$$0 = require('fs');
|
|
4
|
+
var require$$0$1 = require('path');
|
|
5
|
+
var index$1 = require('./index-BUEtH4Dz.cjs');
|
|
6
|
+
var index = require('./index-Bn38UlXg.cjs');
|
|
7
|
+
require('node:dns');
|
|
8
|
+
require('constants');
|
|
9
|
+
require('stream');
|
|
10
|
+
require('util');
|
|
11
|
+
require('assert');
|
|
12
|
+
require('os');
|
|
13
|
+
require('events');
|
|
14
|
+
require('url');
|
|
15
|
+
require('node:child_process');
|
|
16
|
+
require('node:fs/promises');
|
|
17
|
+
require('node:os');
|
|
18
|
+
require('node:path');
|
|
19
|
+
require('node:process');
|
|
20
|
+
require('node:util');
|
|
21
|
+
require('node:events');
|
|
22
|
+
require('node:fs');
|
|
23
|
+
require('node:stream');
|
|
24
|
+
require('better-sqlite3');
|
|
25
|
+
require('http');
|
|
26
|
+
require('https');
|
|
27
|
+
require('crypto');
|
|
28
|
+
require('http2');
|
|
29
|
+
require('tty');
|
|
30
|
+
require('zlib');
|
|
31
|
+
require('child_process');
|
|
32
|
+
require('ntsuspend');
|
|
33
|
+
require('node:readline');
|
|
34
|
+
require('node:crypto');
|
|
35
|
+
require('node:https');
|
|
36
|
+
require('node:url');
|
|
37
|
+
require('net');
|
|
38
|
+
require('node:http');
|
|
39
|
+
require('dns');
|
|
40
|
+
require('tls');
|
|
41
|
+
require('punycode');
|
|
42
|
+
require('@napi-rs/canvas');
|
|
43
|
+
require('vm');
|
|
44
|
+
require('node:stream/promises');
|
|
45
|
+
require('fs/promises');
|
|
46
|
+
require('node:assert');
|
|
47
|
+
require('node:net');
|
|
48
|
+
require('node:querystring');
|
|
49
|
+
require('node:diagnostics_channel');
|
|
50
|
+
require('node:tls');
|
|
51
|
+
require('node:buffer');
|
|
52
|
+
require('node:zlib');
|
|
53
|
+
require('node:perf_hooks');
|
|
54
|
+
require('node:util/types');
|
|
55
|
+
require('node:sqlite');
|
|
56
|
+
require('node:worker_threads');
|
|
57
|
+
require('node:async_hooks');
|
|
58
|
+
require('node:console');
|
|
59
|
+
require('node:timers');
|
|
60
|
+
require('buffer');
|
|
61
|
+
require('querystring');
|
|
62
|
+
require('async_hooks');
|
|
63
|
+
require('string_decoder');
|
|
64
|
+
require('music-segment-detector');
|
|
65
|
+
require('node:stream/web');
|
|
66
|
+
require('shazamio-core');
|
|
67
|
+
|
|
68
|
+
/*! node-domexception. MIT License. Jimmy Wärting <https://jimmy.warting.se/opensource> */
|
|
69
|
+
|
|
70
|
+
if (!globalThis.DOMException) {
|
|
71
|
+
try {
|
|
72
|
+
const { MessageChannel } = require('worker_threads'),
|
|
73
|
+
port = new MessageChannel().port1,
|
|
74
|
+
ab = new ArrayBuffer();
|
|
75
|
+
port.postMessage(ab, [ab, ab]);
|
|
76
|
+
} catch (err) {
|
|
77
|
+
err.constructor.name === 'DOMException' && (
|
|
78
|
+
globalThis.DOMException = err.constructor
|
|
79
|
+
);
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
var nodeDomexception = globalThis.DOMException;
|
|
84
|
+
|
|
85
|
+
var DOMException = /*@__PURE__*/index$1.getDefaultExportFromCjs(nodeDomexception);
|
|
86
|
+
|
|
87
|
+
const getType = (value) => (Object.prototype.toString.call(value).slice(8, -1).toLowerCase());
|
|
88
|
+
function isPlainObject(value) {
|
|
89
|
+
if (getType(value) !== "object") {
|
|
90
|
+
return false;
|
|
91
|
+
}
|
|
92
|
+
const pp = Object.getPrototypeOf(value);
|
|
93
|
+
if (pp === null || pp === undefined) {
|
|
94
|
+
return true;
|
|
95
|
+
}
|
|
96
|
+
const Ctor = pp.constructor && pp.constructor.toString();
|
|
97
|
+
return Ctor === Object.toString();
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
var __classPrivateFieldSet = (undefined && undefined.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
|
|
101
|
+
if (kind === "m") throw new TypeError("Private method is not writable");
|
|
102
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
|
|
103
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
|
|
104
|
+
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
|
|
105
|
+
};
|
|
106
|
+
var __classPrivateFieldGet = (undefined && undefined.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
107
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
|
|
108
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
109
|
+
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
110
|
+
};
|
|
111
|
+
var _FileFromPath_path, _FileFromPath_start;
|
|
112
|
+
const MESSAGE = "The requested file could not be read, "
|
|
113
|
+
+ "typically due to permission problems that have occurred after a reference "
|
|
114
|
+
+ "to a file was acquired.";
|
|
115
|
+
class FileFromPath {
|
|
116
|
+
constructor(input) {
|
|
117
|
+
_FileFromPath_path.set(this, void 0);
|
|
118
|
+
_FileFromPath_start.set(this, void 0);
|
|
119
|
+
__classPrivateFieldSet(this, _FileFromPath_path, input.path, "f");
|
|
120
|
+
__classPrivateFieldSet(this, _FileFromPath_start, input.start || 0, "f");
|
|
121
|
+
this.name = require$$0$1.basename(__classPrivateFieldGet(this, _FileFromPath_path, "f"));
|
|
122
|
+
this.size = input.size;
|
|
123
|
+
this.lastModified = input.lastModified;
|
|
124
|
+
}
|
|
125
|
+
slice(start, end) {
|
|
126
|
+
return new FileFromPath({
|
|
127
|
+
path: __classPrivateFieldGet(this, _FileFromPath_path, "f"),
|
|
128
|
+
lastModified: this.lastModified,
|
|
129
|
+
size: end - start,
|
|
130
|
+
start
|
|
131
|
+
});
|
|
132
|
+
}
|
|
133
|
+
async *stream() {
|
|
134
|
+
const { mtimeMs } = await require$$0.promises.stat(__classPrivateFieldGet(this, _FileFromPath_path, "f"));
|
|
135
|
+
if (mtimeMs > this.lastModified) {
|
|
136
|
+
throw new DOMException(MESSAGE, "NotReadableError");
|
|
137
|
+
}
|
|
138
|
+
if (this.size) {
|
|
139
|
+
yield* require$$0.createReadStream(__classPrivateFieldGet(this, _FileFromPath_path, "f"), {
|
|
140
|
+
start: __classPrivateFieldGet(this, _FileFromPath_start, "f"),
|
|
141
|
+
end: __classPrivateFieldGet(this, _FileFromPath_start, "f") + this.size - 1
|
|
142
|
+
});
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
get [(_FileFromPath_path = new WeakMap(), _FileFromPath_start = new WeakMap(), Symbol.toStringTag)]() {
|
|
146
|
+
return "File";
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
function createFileFromPath(path, { mtimeMs, size }, filenameOrOptions, options = {}) {
|
|
150
|
+
let filename;
|
|
151
|
+
if (isPlainObject(filenameOrOptions)) {
|
|
152
|
+
[options, filename] = [filenameOrOptions, undefined];
|
|
153
|
+
}
|
|
154
|
+
else {
|
|
155
|
+
filename = filenameOrOptions;
|
|
156
|
+
}
|
|
157
|
+
const file = new FileFromPath({ path, size, lastModified: mtimeMs });
|
|
158
|
+
if (!filename) {
|
|
159
|
+
filename = file.name;
|
|
160
|
+
}
|
|
161
|
+
return new index.File([file], filename, {
|
|
162
|
+
...options, lastModified: file.lastModified
|
|
163
|
+
});
|
|
164
|
+
}
|
|
165
|
+
async function fileFromPath(path, filenameOrOptions, options) {
|
|
166
|
+
const stats = await require$$0.promises.stat(path);
|
|
167
|
+
return createFileFromPath(path, stats, filenameOrOptions, options);
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
exports.isFile = index.isFile;
|
|
171
|
+
exports.fileFromPath = fileFromPath;
|
|
@@ -11448,6 +11448,22 @@ const Scheduler = {
|
|
|
11448
11448
|
}
|
|
11449
11449
|
};
|
|
11450
11450
|
|
|
11451
|
+
/* IMPORT */
|
|
11452
|
+
/* MAIN */
|
|
11453
|
+
const IS_LINUX = (process$2.platform === 'linux');
|
|
11454
|
+
const IS_WINDOWS = (process$2.platform === 'win32');
|
|
11455
|
+
|
|
11456
|
+
/* IMPORT */
|
|
11457
|
+
/* MAIN */
|
|
11458
|
+
//URL: https://github.com/tapjs/signal-exit/blob/458776d9cf8be89712aa1f7b45bb2163ce15ef4a/src/signals.ts
|
|
11459
|
+
const Signals = ['SIGHUP', 'SIGINT', 'SIGTERM'];
|
|
11460
|
+
if (!IS_WINDOWS) {
|
|
11461
|
+
Signals.push('SIGALRM', 'SIGABRT', 'SIGVTALRM', 'SIGXCPU', 'SIGXFSZ', 'SIGUSR2', 'SIGTRAP', 'SIGSYS', 'SIGQUIT', 'SIGIOT');
|
|
11462
|
+
}
|
|
11463
|
+
if (IS_LINUX) {
|
|
11464
|
+
Signals.push('SIGIO', 'SIGPOLL', 'SIGPWR', 'SIGSTKFLT');
|
|
11465
|
+
}
|
|
11466
|
+
|
|
11451
11467
|
/* IMPORT */
|
|
11452
11468
|
/* MAIN */
|
|
11453
11469
|
class Interceptor {
|
|
@@ -11455,14 +11471,34 @@ class Interceptor {
|
|
|
11455
11471
|
constructor() {
|
|
11456
11472
|
/* VARIABLES */
|
|
11457
11473
|
this.callbacks = new Set();
|
|
11474
|
+
this.exited = false;
|
|
11458
11475
|
/* API */
|
|
11459
|
-
this.exit = () => {
|
|
11476
|
+
this.exit = (signal) => {
|
|
11477
|
+
if (this.exited)
|
|
11478
|
+
return;
|
|
11479
|
+
this.exited = true;
|
|
11460
11480
|
for (const callback of this.callbacks) {
|
|
11461
11481
|
callback();
|
|
11462
11482
|
}
|
|
11483
|
+
if (signal) {
|
|
11484
|
+
if (IS_WINDOWS && (signal !== 'SIGINT' && signal !== 'SIGTERM' && signal !== 'SIGKILL')) { // Windows doesn't support POSIX signals, but Node emulates these 3 signals for us
|
|
11485
|
+
process$2.kill(process$2.pid, 'SIGTERM');
|
|
11486
|
+
}
|
|
11487
|
+
else {
|
|
11488
|
+
process$2.kill(process$2.pid, signal);
|
|
11489
|
+
}
|
|
11490
|
+
}
|
|
11463
11491
|
};
|
|
11464
11492
|
this.hook = () => {
|
|
11465
|
-
|
|
11493
|
+
process$2.once('exit', () => this.exit());
|
|
11494
|
+
for (const signal of Signals) {
|
|
11495
|
+
try {
|
|
11496
|
+
process$2.once(signal, () => this.exit(signal));
|
|
11497
|
+
}
|
|
11498
|
+
catch {
|
|
11499
|
+
// Sometimes "process.once" can throw...
|
|
11500
|
+
}
|
|
11501
|
+
}
|
|
11466
11502
|
};
|
|
11467
11503
|
this.register = (callback) => {
|
|
11468
11504
|
this.callbacks.add(callback);
|
|
@@ -54888,7 +54924,7 @@ async function trash(paths, options) {
|
|
|
54888
54924
|
} else if (process$2.platform === 'win32') {
|
|
54889
54925
|
module = await Promise.resolve().then(function () { return require('./windows-OmnJ7a39.cjs'); });
|
|
54890
54926
|
} else {
|
|
54891
|
-
module = await Promise.resolve().then(function () { return require('./linux-
|
|
54927
|
+
module = await Promise.resolve().then(function () { return require('./linux-9g8WByl9.cjs'); });
|
|
54892
54928
|
}
|
|
54893
54929
|
|
|
54894
54930
|
return module.default(paths);
|
|
@@ -75478,15 +75514,23 @@ var Stream$1 = /*#__PURE__*/function () {
|
|
|
75478
75514
|
return Stream;
|
|
75479
75515
|
}();
|
|
75480
75516
|
|
|
75481
|
-
|
|
75482
|
-
|
|
75483
|
-
|
|
75484
|
-
|
|
75485
|
-
|
|
75486
|
-
|
|
75487
|
-
|
|
75488
|
-
|
|
75489
|
-
}
|
|
75517
|
+
var _extends$1 = {exports: {}};
|
|
75518
|
+
|
|
75519
|
+
(function (module) {
|
|
75520
|
+
function _extends() {
|
|
75521
|
+
return module.exports = _extends = Object.assign ? Object.assign.bind() : function (n) {
|
|
75522
|
+
for (var e = 1; e < arguments.length; e++) {
|
|
75523
|
+
var t = arguments[e];
|
|
75524
|
+
for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]);
|
|
75525
|
+
}
|
|
75526
|
+
return n;
|
|
75527
|
+
}, module.exports.__esModule = true, module.exports["default"] = module.exports, _extends.apply(null, arguments);
|
|
75528
|
+
}
|
|
75529
|
+
module.exports = _extends, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
75530
|
+
} (_extends$1));
|
|
75531
|
+
|
|
75532
|
+
var _extendsExports = _extends$1.exports;
|
|
75533
|
+
var _extends = /*@__PURE__*/getDefaultExportFromCjs(_extendsExports);
|
|
75490
75534
|
|
|
75491
75535
|
var win;
|
|
75492
75536
|
|
|
@@ -303540,9 +303584,12 @@ exports.DouyinDownloadVideoTask = DouyinDownloadVideoTask;
|
|
|
303540
303584
|
exports.FFmpegPreset = FFmpegPreset;
|
|
303541
303585
|
exports.FlvRepairTask = FlvRepairTask;
|
|
303542
303586
|
exports.FormData = FormData$2;
|
|
303587
|
+
exports.Headers = Headers$1;
|
|
303543
303588
|
exports.KuaishouDownloadVideoTask = KuaishouDownloadVideoTask;
|
|
303544
303589
|
exports.M3U8Downloader = M3U8Downloader;
|
|
303545
303590
|
exports.Pan123 = Pan123;
|
|
303591
|
+
exports.Request = Request$3;
|
|
303592
|
+
exports.Response = Response$1;
|
|
303546
303593
|
exports.SpeedCalculator = SpeedCalculator;
|
|
303547
303594
|
exports.SyncTask = SyncTask;
|
|
303548
303595
|
exports.Throttle = Throttle$1;
|
|
@@ -303575,6 +303622,7 @@ exports.esDefineProperty = esDefineProperty;
|
|
|
303575
303622
|
exports.escaped = escaped;
|
|
303576
303623
|
exports.executeVirtualRecordConfig = executeVirtualRecordConfig;
|
|
303577
303624
|
exports.extension = extension$3;
|
|
303625
|
+
exports.fetch = fetch$2;
|
|
303578
303626
|
exports.formatDesc = formatDesc;
|
|
303579
303627
|
exports.formatPartTitle = formatPartTitle;
|
|
303580
303628
|
exports.formatTitle = formatTitle;
|