mirror of
https://github.com/zhenxun-org/zhenxun_bot.git
synced 2025-12-15 14:22:55 +08:00
46 lines
8.6 KiB
HTML
46 lines
8.6 KiB
HTML
<!DOCTYPE html>
|
||
<html lang="en-US">
|
||
<head>
|
||
<meta charset="utf-8">
|
||
<meta name="viewport" content="width=device-width,initial-scale=1">
|
||
<title>指南 | 真寻Bot</title>
|
||
<meta name="generator" content="VuePress 1.8.2">
|
||
<link rel="icon" href="/zhenxun_bot/favicon.ico">
|
||
<meta name="description" content="非常可爱的多功能机器人!">
|
||
|
||
<link rel="preload" href="/zhenxun_bot/assets/css/0.styles.7deda930.css" as="style"><link rel="preload" href="/zhenxun_bot/assets/js/app.53d300b0.js" as="script"><link rel="preload" href="/zhenxun_bot/assets/js/2.7d7efdaa.js" as="script"><link rel="preload" href="/zhenxun_bot/assets/js/8.6bb0baec.js" as="script"><link rel="prefetch" href="/zhenxun_bot/assets/js/10.c59f6c61.js"><link rel="prefetch" href="/zhenxun_bot/assets/js/3.d8535281.js"><link rel="prefetch" href="/zhenxun_bot/assets/js/4.184eba5b.js"><link rel="prefetch" href="/zhenxun_bot/assets/js/5.f15be490.js"><link rel="prefetch" href="/zhenxun_bot/assets/js/6.9b9ba81c.js"><link rel="prefetch" href="/zhenxun_bot/assets/js/7.115a23f4.js"><link rel="prefetch" href="/zhenxun_bot/assets/js/9.5238d1a7.js">
|
||
<link rel="stylesheet" href="/zhenxun_bot/assets/css/0.styles.7deda930.css">
|
||
</head>
|
||
<body>
|
||
<div id="app" data-server-rendered="true"><div class="theme-container"><header class="navbar"><div class="sidebar-button"><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" role="img" viewBox="0 0 448 512" class="icon"><path fill="currentColor" d="M436 124H12c-6.627 0-12-5.373-12-12V80c0-6.627 5.373-12 12-12h424c6.627 0 12 5.373 12 12v32c0 6.627-5.373 12-12 12zm0 160H12c-6.627 0-12-5.373-12-12v-32c0-6.627 5.373-12 12-12h424c6.627 0 12 5.373 12 12v32c0 6.627-5.373 12-12 12zm0 160H12c-6.627 0-12-5.373-12-12v-32c0-6.627 5.373-12 12-12h424c6.627 0 12 5.373 12 12v32c0 6.627-5.373 12-12 12z"></path></svg></div> <a href="/zhenxun_bot/" class="home-link router-link-active"><!----> <span class="site-name">真寻Bot</span></a> <div class="links"><div class="search-box"><input aria-label="Search" autocomplete="off" spellcheck="false" value=""> <!----></div> <nav class="nav-links can-hide"><div class="nav-item"><a href="/zhenxun_bot/" class="nav-link">
|
||
主页
|
||
</a></div><div class="nav-item"><a href="/zhenxun_bot/guide/" aria-current="page" class="nav-link router-link-exact-active router-link-active">
|
||
指南
|
||
</a></div><div class="nav-item"><a href="/zhenxun_bot/help/" class="nav-link">
|
||
帮助
|
||
</a></div><div class="nav-item"><a href="/zhenxun_bot/updatalogs/" class="nav-link">
|
||
更新日志
|
||
</a></div><div class="nav-item"><a href="https://github.com/HibiKier/zhenxun_bot" target="_blank" rel="noopener noreferrer" class="nav-link external">
|
||
Github Page
|
||
<span><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewBox="0 0 100 100" width="15" height="15" class="icon outbound"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path> <polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg> <span class="sr-only">(opens new window)</span></span></a></div> <!----></nav></div></header> <div class="sidebar-mask"></div> <aside class="sidebar"><nav class="nav-links"><div class="nav-item"><a href="/zhenxun_bot/" class="nav-link">
|
||
主页
|
||
</a></div><div class="nav-item"><a href="/zhenxun_bot/guide/" aria-current="page" class="nav-link router-link-exact-active router-link-active">
|
||
指南
|
||
</a></div><div class="nav-item"><a href="/zhenxun_bot/help/" class="nav-link">
|
||
帮助
|
||
</a></div><div class="nav-item"><a href="/zhenxun_bot/updatalogs/" class="nav-link">
|
||
更新日志
|
||
</a></div><div class="nav-item"><a href="https://github.com/HibiKier/zhenxun_bot" target="_blank" rel="noopener noreferrer" class="nav-link external">
|
||
Github Page
|
||
<span><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewBox="0 0 100 100" width="15" height="15" class="icon outbound"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path> <polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg> <span class="sr-only">(opens new window)</span></span></a></div> <!----></nav> <ul class="sidebar-links"><li><section class="sidebar-group depth-0"><p class="sidebar-heading open"><span>指南</span> <!----></p> <ul class="sidebar-links sidebar-group-items"><li><a href="/zhenxun_bot/guide/#部署" class="sidebar-link">部署</a><ul class="sidebar-sub-headers"><li class="sidebar-sub-header"><a href="/zhenxun_bot/guide/#配置gocq" class="sidebar-link">配置gocq</a></li><li class="sidebar-sub-header"><a href="/zhenxun_bot/guide/#获取源码" class="sidebar-link">获取源码</a></li><li class="sidebar-sub-header"><a href="/zhenxun_bot/guide/#开始运行" class="sidebar-link">开始运行</a></li></ul></li><li><a href="/zhenxun_bot/guide/#配置" class="sidebar-link">配置</a><ul class="sidebar-sub-headers"><li class="sidebar-sub-header"><a href="/zhenxun_bot/guide/#在-env-dev文件中" class="sidebar-link">在.env.dev文件中</a></li><li class="sidebar-sub-header"><a href="/zhenxun_bot/guide/#在configs-config-py文件中" class="sidebar-link">在configs/config.py文件中</a></li></ul></li></ul></section></li></ul> </aside> <main class="page"> <div class="theme-default-content content__default"><h2 id="部署"><a href="#部署" class="header-anchor">#</a> 部署</h2> <h3 id="配置gocq"><a href="#配置gocq" class="header-anchor">#</a> 配置gocq</h3> <p>在 <a href="https://github.com/Mrs4s/go-cqhttp" target="_blank" rel="noopener noreferrer">https://github.com/Mrs4s/go-cqhttp<span><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" x="0px" y="0px" viewBox="0 0 100 100" width="15" height="15" class="icon outbound"><path fill="currentColor" d="M18.8,85.1h56l0,0c2.2,0,4-1.8,4-4v-32h-8v28h-48v-48h28v-8h-32l0,0c-2.2,0-4,1.8-4,4v56C14.8,83.3,16.6,85.1,18.8,85.1z"></path> <polygon fill="currentColor" points="45.7,48.7 51.3,54.3 77.2,28.5 77.2,37.2 85.2,37.2 85.2,14.9 62.8,14.9 62.8,22.9 71.5,22.9"></polygon></svg> <span class="sr-only">(opens new window)</span></span></a> 下载Releases最新版本,运行后选择反向代理。</p> <p>后将 go-cqhttp 的配置文件 config.yml 中的 universal 改为 universal: ws://127.0.0.1:8080/cqhttp/ws</p> <h3 id="获取源码"><a href="#获取源码" class="header-anchor">#</a> 获取源码</h3> <div class="language- extra-class"><pre class="language-text"><code>git clone https://github.com/HibiKier/zhenxun_bot.git //克隆仓库
|
||
|
||
cd zhenxun_bot //进入目录
|
||
|
||
pip install -r requirements.txt //安装依赖
|
||
</code></pre></div><p><strong>进行基础配置</strong></p> <blockquote><p>请查看 <strong>配置</strong> 部分</p></blockquote> <h3 id="开始运行"><a href="#开始运行" class="header-anchor">#</a> 开始运行</h3> <div class="language- extra-class"><pre class="language-text"><code>python bot.py
|
||
</code></pre></div><h2 id="配置"><a href="#配置" class="header-anchor">#</a> 配置</h2> <p><strong>在 configs/config.py 中的 USE_CONFIG_FILE,默认为 False</strong></p> <blockquote><p><strong>#如果不使用配置文件,将 USE_CONFIG_FILE 设置为 False</strong></p></blockquote> <h3 id="在-env-dev文件中"><a href="#在-env-dev文件中" class="header-anchor">#</a> 在.env.dev文件中</h3> <div class="language- extra-class"><pre class="language-text"><code>SUPERUSERS = [""] # 填写你的QQ
|
||
</code></pre></div><h3 id="在configs-config-py文件中"><a href="#在configs-config-py文件中" class="header-anchor">#</a> 在configs/config.py文件中</h3> <p><strong>必填:</strong></p> <ul><li>API KEY</li> <li>数据库配置</li></ul> <p>在./configs/config.py中配置基本配置(除API KEY ,数据库和代理外都含有默认值)</p> <p>在./configs/path_config.py配置路径(含有默认配置)</p> <blockquote><p><strong>#可在 ./configs/config.py 文件中修改配置,在 ./configs/path_config.py 修改资源路径</strong></p></blockquote> <blockquote><p><strong>#已在 ./configs/config.py 和 ./configs/path_config.py 中为各个配置提供注解!</strong></p></blockquote></div> <footer class="page-edit"><!----> <!----></footer> <!----> </main></div><div class="global-ui"></div></div>
|
||
<script src="/zhenxun_bot/assets/js/app.53d300b0.js" defer></script><script src="/zhenxun_bot/assets/js/2.7d7efdaa.js" defer></script><script src="/zhenxun_bot/assets/js/8.6bb0baec.js" defer></script>
|
||
</body>
|
||
</html>
|