A Epic free game info plugin for Nonebot2
Project description
Nonebot Plugin EpicFree
🤖 用于获取 Epic 限免游戏资讯的 Nonebot2 插件
安装方法
可以使用以下两命令快速安装,但请注意可能引起的依赖版本冲突。
如果 pip
配置了 PyPI 镜像(推荐清华大学 PyPI 镜像),你可能无法及时检索到插件最新版本。
nb plugin install nonebot_plugin_epicfree
# or
pip install --upgrade nonebot_plugin_epicfree
**关于依赖版本**
以上述方式安装本插件时,可能由于版本差异引起报错,对于新手推荐在安装插件前先存留当前环境依赖版本,以便后续恢复:
# 备份当前的依赖版本
pip3 freeze > requirements.txt
# 尝试安装 nonebot_plugin_epicfree
# 安装备份的依赖版本
pip3 install -r requirements.txt
如果安装前未存留备份,可以在 安装完本插件后,使用 pip3 install --upgrade nb-cli
按最新版本 nb-cli
的依赖重新安装,实测不影响此插件使用。
建议使用 Python 虚拟环境。
在 Nonebot2 入口文件(例如 bot.py
)增加:
nonebot.load_plugin("nonebot_plugin_epicfree")
指令详解
# nonebot_plugin_epicfree/nonebot_plugin_epicfree/__init__.py#L7
matcher = on_regex("((E|e)(P|p)(I|i)(C|c))?喜(加一|\+1)")
基于正则匹配,所以,甚至 EpIc喜+1
这样的指令都可用!(
如果你觉得不顺眼也可以自己参考 Nonebot2 文档修改下。
特别鸣谢
@nonebot/nonebot2 | @Mrs4s/go-cqhttp | @DIYgod/RSSHub | @SD4RK/epicstore_api
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for nonebot_plugin_epicfree-0.1.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 26278511931a4b494c73791c8df853d7fdbc17c5244b167f237eea896bf770d0 |
|
MD5 | bb39ad5571fb619c58692e7fb896d2ae |
|
BLAKE2b-256 | 887e6cb2971003fed56afbe842bb995114a4456907712340cffa2acec65d0370 |
Close
Hashes for nonebot_plugin_epicfree-0.1.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 08004fffa1e72eb58b757b984752c1787b0cecf48824fed6c9e5d5445ee8a676 |
|
MD5 | 5788c718a712ad52b92c31a9305826f2 |
|
BLAKE2b-256 | 19d2da276abd48f4e80a890e8d147331d16cbfe2da3ccc6887ca4468683ba477 |