📖 介绍
记录b站视频链接分享,并提示多次分享
💿 安装
使用 nb-cli 安装
在 nonebot2 项目的根目录下打开命令行, 输入以下指令即可安装nb plugin install nonebot-plugin-bili-share-keeper
使用包管理器安装
在 nonebot2 项目的插件目录下, 打开命令行, 根据你使用的包管理器, 输入相应的安装命令pip
pip install nonebot-plugin-bili-share-keeper
pdm
pdm add nonebot-plugin-bili-share-keeper
poetry
poetry add nonebot-bili-share-keeper
conda
conda install nonebot-bili-share-keeper
打开 nonebot2 项目根目录下的 pyproject.toml 文件, 在 [tool.nonebot] 部分追加写入
plugins = ["nonebot_plugin_bili-share-keeper"]
⚙️ 配置
在 nonebot2 项目的.env文件中添加下表中的必填配置
| 配置项 | 必填 | 默认值 | 说明 |
|---|---|---|---|
| bilibili_share_keeper_redis_url | 否 | redis://localhost:6379/0 | redis数据库地址,不填或不可用时自动退回内存存储 |
| bilibili_share_keeper_target_group | 是 | 无 | 开启此插件的群聊,支持单个群号或多个群号 |
| bilibili_share_keeper_key_prefix | 否 | nb2:bili_share_keeper | redis中记录的前缀 |
| bilibili_share_keeper_http_timeout | 否 | 10 | http请求的超时值 |
bilibili_share_keeper_target_group 配置示例
支持以下形式:
# 单个群
bilibili_share_keeper_target_group=123456
# 多个群(推荐 JSON 数组)
bilibili_share_keeper_target_group=[123456, 234567, 345678]
# 多个群(逗号分隔)
bilibili_share_keeper_target_group=123456,234567,345678
🕹️ 使用
在第二次及以上的时候分享B站链接视频会出现“此视频已于{datetime}被群友{群友名称}分享过,这是第{分享次数}次被分享”
Metadata
Release files for nonebot-plugin-bili-share-keeper 0.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| nonebot_plugin_bili_share_keeper-0.0.2.tar.gz | 6.8 kB | With provenance | Details for nonebot_plugin_bili_share_keeper-0.0.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| nonebot_plugin_bili_share_keeper-0.0.2-py3-none-any.whl | Python 3 | none | any | Details for nonebot_plugin_bili_share_keeper-0.0.2-py3-none-any.whl |
Total release size: 14.7 kB
Security for nonebot-plugin-bili-share-keeper 0.0.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.