dsh-bili-video 0.1.0 → 0.1.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/LICENSE +1 -1
- package/README.md +3 -3
- package/package.json +2 -6
- package/src/index.js +1 -1
package/LICENSE
CHANGED
package/README.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
把 B 站视频搬进 QQ 群的 DSH 插件:群里出现 B 站链接或小程序卡片时,自动解析、下载、合并并发送为 QQ 视频消息;也可以由 Agent 直接调用 `bili_relay` 工具。
|
|
4
4
|
|
|
5
|
-
>
|
|
5
|
+
> 这是 dsh-bili-video 的独立发布仓库,npm 包名为 `dsh-bili-video`。插件运行数据(`data/`、`secrets/`)由 `root` 目录自行管理,不随包发布。
|
|
6
6
|
|
|
7
7
|
## 功能
|
|
8
8
|
|
|
@@ -33,7 +33,7 @@ dsh plugin --profile desktop add dsh-bili-video
|
|
|
33
33
|
- id: bili-video
|
|
34
34
|
name: dsh-bili-video
|
|
35
35
|
config:
|
|
36
|
-
root: /path/to/
|
|
36
|
+
root: /path/to/dsh-bili-video-data
|
|
37
37
|
groups: "123456789"
|
|
38
38
|
maxBytes: 31457280
|
|
39
39
|
maxDurationSec: 900
|
|
@@ -44,7 +44,7 @@ dsh plugin --profile desktop add dsh-bili-video
|
|
|
44
44
|
|
|
45
45
|
| 字段 | 说明 |
|
|
46
46
|
|---|---|
|
|
47
|
-
| `root` | 数据根目录;默认当前工作目录,也可用 `
|
|
47
|
+
| `root` | 数据根目录;默认当前工作目录,也可用 `BILI_VIDEO_ROOT` 环境变量 |
|
|
48
48
|
| `groups` | 允许搬运的真实群号,逗号分隔;留空表示不限制,生产环境不建议留空 |
|
|
49
49
|
| `maxBytes` | 内联上限,默认 31457280(30MB) |
|
|
50
50
|
| `maxDurationSec` | 时长上限,默认 900(15 分钟) |
|
package/package.json
CHANGED
|
@@ -1,16 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-bili-video",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.1",
|
|
4
4
|
"description": "DSH 插件:B 站视频搬运到 QQ 群(≤15 分钟、30MB 内联、分片上传、6 小时去重)",
|
|
5
|
-
"author": "
|
|
5
|
+
"author": "dsh-bili-video contributors",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
8
8
|
"url": "git+https://github.com/lucifermbbgh/dsh-bilivideo-qqbot-forward-plugin.git"
|
|
9
9
|
},
|
|
10
|
-
"homepage": "https://github.com/lucifermbbgh/dsh-bilivideo-qqbot-forward-plugin#readme",
|
|
11
|
-
"bugs": {
|
|
12
|
-
"url": "https://github.com/lucifermbbgh/dsh-bilivideo-qqbot-forward-plugin/issues"
|
|
13
|
-
},
|
|
14
10
|
"type": "module",
|
|
15
11
|
"main": "./src/index.js",
|
|
16
12
|
"engines": {
|
package/src/index.js
CHANGED
|
@@ -53,7 +53,7 @@ function findBili(ev) {
|
|
|
53
53
|
}
|
|
54
54
|
|
|
55
55
|
export function apply(ctx, config = {}) {
|
|
56
|
-
const root = config.root || process.env.
|
|
56
|
+
const root = config.root || process.env.BILI_VIDEO_ROOT || process.cwd();
|
|
57
57
|
const cfg = {
|
|
58
58
|
maxBytes: config.maxBytes || 30 * 1024 * 1024,
|
|
59
59
|
maxDurationSec: config.maxDurationSec || 900,
|