dsh-bili-bg 0.11.0 → 0.11.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/README.md +25 -0
- package/index.js +941 -905
- package/lib/bili.js +6 -0
- package/package.json +57 -52
- package/runtime/dash.js +129 -11
- package/runtime/skin.css +108 -0
- package/runtime/skin.js +339 -31
package/README.md
CHANGED
|
@@ -182,4 +182,29 @@ tests/mse.mjs MSE 播放器单测(ISO-BMFF 解析 + 装配/回退)
|
|
|
182
182
|
node tests/smoke.mjs # 宿主冒烟(需外网访问 B 站接口)
|
|
183
183
|
node tests/client.mjs # 客户端 DOM stub 测试
|
|
184
184
|
node tests/mse.mjs # MSE 播放器单测(ISO-BMFF 解析 + 装配/回退)
|
|
185
|
+
npm test # client + mse
|
|
186
|
+
npm run test:all # 全部(含联网 smoke)
|
|
185
187
|
```
|
|
188
|
+
|
|
189
|
+
## 发布(npm)
|
|
190
|
+
|
|
191
|
+
一键发布脚本:`scripts/release.mjs`(Windows 可双击 `release.cmd`)。
|
|
192
|
+
|
|
193
|
+
```bash
|
|
194
|
+
node scripts/release.mjs # 交互选择 patch / minor / major / 自定义版本
|
|
195
|
+
node scripts/release.mjs patch # 0.11.0 → 0.11.1
|
|
196
|
+
node scripts/release.mjs minor # 新功能:0.11.0 → 0.12.0
|
|
197
|
+
node scripts/release.mjs 1.2.3 # 指定版本号
|
|
198
|
+
node scripts/release.mjs patch --dry # 演练:只 bump+测试,不提交/发布/推送
|
|
199
|
+
```
|
|
200
|
+
|
|
201
|
+
脚本会依次:校验工作区干净 → bump `package.json` 与 `index.js` 的 `VERSION` →
|
|
202
|
+
跑测试(默认 client+mse,`--smoke` 加宿主冒烟)→ `git commit` → 提示输入 npm
|
|
203
|
+
二步验证码(隐藏输入,也可用 `NPM_OTP` 环境变量)→ `npm publish` 到官方源 →
|
|
204
|
+
`git push`。
|
|
205
|
+
|
|
206
|
+
其它参数:`--no-push` 不推送、`--no-tests` 跳过测试、`--yes` 免确认、
|
|
207
|
+
`--allow-dirty` 允许脏工作区(不推荐)。
|
|
208
|
+
|
|
209
|
+
> 发布需要先在 npm 启用 2FA(验证器 App),或用带 Bypass 2FA 的 granular token。
|
|
210
|
+
> 默认发布源为 `https://registry.npmjs.org`,可用 `NPM_REGISTRY` 覆盖。
|