bililive-cli 1.2.3
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/LICENSE +674 -0
- package/README.md +40 -0
- package/lib/chunked-exec-D0BsLh9V.js +55 -0
- package/lib/index-BZRzMMRb.js +47 -0
- package/lib/index.cjs +108918 -0
- package/lib/linux-BetMzq9g.js +3581 -0
- package/lib/macos-BaatW38k.js +23 -0
- package/lib/windows-B0oX8Um0.js +16 -0
- package/package.json +47 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var os = require('node:os');
|
|
4
|
+
var chunkedExec = require('./chunked-exec-D0BsLh9V.js');
|
|
5
|
+
require('node:util');
|
|
6
|
+
require('node:child_process');
|
|
7
|
+
require('node:url');
|
|
8
|
+
|
|
9
|
+
var _documentCurrentScript = typeof document !== 'undefined' ? document.currentScript : null;
|
|
10
|
+
const isOlderThanMountainLion = Number(os.release().split('.')[0]) < 12;
|
|
11
|
+
|
|
12
|
+
// Binary source: https://github.com/sindresorhus/macos-trash
|
|
13
|
+
const binary = new URL('macos-trash', (typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.src || new URL('macos-BaatW38k.js', document.baseURI).href)));
|
|
14
|
+
|
|
15
|
+
async function macOS(paths) {
|
|
16
|
+
if (isOlderThanMountainLion) {
|
|
17
|
+
throw new Error('macOS 10.12 or later required');
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
await chunkedExec.chunkedExec(binary, paths, 1000);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
exports.default = macOS;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var chunkedExec = require('./chunked-exec-D0BsLh9V.js');
|
|
4
|
+
require('node:util');
|
|
5
|
+
require('node:child_process');
|
|
6
|
+
require('node:url');
|
|
7
|
+
|
|
8
|
+
var _documentCurrentScript = typeof document !== 'undefined' ? document.currentScript : null;
|
|
9
|
+
// Binary source: https://github.com/sindresorhus/recycle-bin
|
|
10
|
+
const binary = new URL('windows-trash.exe', (typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.src || new URL('windows-B0oX8Um0.js', document.baseURI).href)));
|
|
11
|
+
|
|
12
|
+
async function windows(paths) {
|
|
13
|
+
await chunkedExec.chunkedExec(binary, paths, 200);
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
exports.default = windows;
|
package/package.json
ADDED
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "bililive-cli",
|
|
3
|
+
"version": "1.2.3",
|
|
4
|
+
"type": "module",
|
|
5
|
+
"description": "biliLive-tools的cli程序",
|
|
6
|
+
"main": "./lib/index.js",
|
|
7
|
+
"author": "renmu123",
|
|
8
|
+
"license": "GPL-3.0",
|
|
9
|
+
"homepage": "https://github.com/renmu123/biliLive-tools",
|
|
10
|
+
"bin": {
|
|
11
|
+
"biliLive": "./lib/index.cjs"
|
|
12
|
+
},
|
|
13
|
+
"keywords": [
|
|
14
|
+
"biliLive-tools",
|
|
15
|
+
"cli",
|
|
16
|
+
"录播处理",
|
|
17
|
+
"b站上传",
|
|
18
|
+
"bilibili"
|
|
19
|
+
],
|
|
20
|
+
"files": [
|
|
21
|
+
"lib"
|
|
22
|
+
],
|
|
23
|
+
"dependencies": {
|
|
24
|
+
"@napi-rs/canvas": "^0.1.53"
|
|
25
|
+
},
|
|
26
|
+
"devDependencies": {
|
|
27
|
+
"@types/cli-progress": "^3.11.5",
|
|
28
|
+
"@yao-pkg/pkg": "^5.11.5",
|
|
29
|
+
"bestzip": "^2.2.1",
|
|
30
|
+
"rollup-plugin-natives": "^0.7.8",
|
|
31
|
+
"tsx": "^4.7.2",
|
|
32
|
+
"cli-progress": "^3.12.0",
|
|
33
|
+
"commander": "^12.0.0",
|
|
34
|
+
"@biliLive-tools/shared": "1.2.0",
|
|
35
|
+
"@biliLive-tools/types": "1.2.0",
|
|
36
|
+
"@biliLive-tools/http": "1.2.0"
|
|
37
|
+
},
|
|
38
|
+
"scripts": {
|
|
39
|
+
"start": "tsx src/index.ts",
|
|
40
|
+
"dev": "rollup --config rollup.config.js -w",
|
|
41
|
+
"build:cli": "pnpm run build && pnpm run pkg",
|
|
42
|
+
"build": "rollup --config rollup.config.js",
|
|
43
|
+
"pkg": "pkg ./lib/index.cjs --output ./dist/biliLive",
|
|
44
|
+
"zip:win": "cd dist && bestzip biliLive-cli-win-x64.zip ./biliLive.exe",
|
|
45
|
+
"zip:linux": "cd dist && bestzip biliLive-cli-linux-x64.zip ./biliLive"
|
|
46
|
+
}
|
|
47
|
+
}
|