From 36d4a086ddfb806995e2e742b32e266118710b1b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=B9=B0=E5=AE=9A=E4=B8=8D=E7=A6=BB=E6=89=8B?= <12640033+msz-006@user.noreply.gitee.com> Date: Mon, 14 Jul 2025 03:36:59 +0800 Subject: [PATCH] =?UTF-8?q?docs:=20=E5=9C=A8=E9=BB=98=E8=AE=A4=E8=AF=B4?= =?UTF-8?q?=E6=98=8E=E6=96=87=E6=A1=A3=E4=B8=AD=E5=8A=A0=E5=85=A5SQLite?= =?UTF-8?q?=E6=94=AF=E6=8C=81=E8=AF=B4=E6=98=8E\n\n-=20=E6=9B=B4=E6=96=B0?= =?UTF-8?q?=20docs/index.md=20=E6=96=87=E4=BB=B6=EF=BC=8C=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0=E5=AF=B9SQLite=E6=95=B0=E6=8D=AE=E5=BA=93=E7=9A=84?= =?UTF-8?q?=E6=94=AF=E6=8C=81=E8=AF=B4=E6=98=8E\n-=20=E6=B7=BB=E5=8A=A0SQL?= =?UTF-8?q?ite=E4=BD=BF=E7=94=A8=E7=A4=BA=E4=BE=8B=E5=92=8C=E9=85=8D?= =?UTF-8?q?=E7=BD=AE=E8=AF=B4=E6=98=8E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/index.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/docs/index.md b/docs/index.md index 351a19e..6018b81 100644 --- a/docs/index.md +++ b/docs/index.md @@ -41,6 +41,12 @@ # 从配置文件中读取指定的帖子ID列表获取指定帖子的信息与评论信息 python main.py --platform xhs --lt qrcode --type detail + + # 使用SQLite数据库存储数据(推荐个人用户使用) + python main.py --platform xhs --lt qrcode --type search --save_data_option sqlite + + # 使用MySQL数据库存储数据 + python main.py --platform xhs --lt qrcode --type search --save_data_option db # 打开对应APP扫二维码登录 @@ -51,6 +57,10 @@ ## 数据保存 - 支持关系型数据库Mysql中保存(需要提前创建数据库) - 执行 `python db.py` 初始化数据库数据库表结构(只在首次执行) +- 支持轻量级SQLite数据库保存(无需额外安装数据库服务器) + - 本地文件数据库,适合个人使用和小规模数据存储 + - 使用参数 `--save_data_option sqlite` 启用SQLite存储 + - 数据库文件自动创建在项目目录下(schema/sqlite_tables.db) - 支持保存到csv中(data/目录下) - 支持保存到json中(data/目录下)