A command-line tool for downloading Chinese web novels from Qidian and similar platforms.
Project description
novel-downloader
一个基于 DrissionPage 和 requests 的小说下载工具/库。
项目简介
novel-downloader 支持多种小说网站的章节抓取与合并导出,
- 轻量化抓取: 绝大多数站点仅依赖
requests实现 HTTP 请求, 无需额外浏览器驱动 - 对于起点中文网 (Qidian), 可在配置中选择:
mode: session: 纯 Requests 模式mode: browser: 基于DrissionPage驱动 Chrome 的浏览器模式 (可处理更复杂的 JS/加密)。
- 自动登录 (可选)
- 配置
login_required: true后自动检测并重用历史 Cookie - 首次登录或 Cookie 失效时:
- browser 模式: 在程序打开的浏览器窗口登录, 登录后回车继续
- session 模式: 根据提示粘贴浏览器中已登录的 Cookie (参考 复制 Cookies)
- 配置
功能特性
- 抓取起点中文网免费及已订阅章节内容
- 支持断点续爬, 自动续传未完成任务
- 自动整合所有章节并导出为:
- TXT
- EPUB (可选包含章节插图)
- 支持活动广告过滤:
- 章节标题
- 章节正文
快速开始
# 克隆 + 安装
pip install novel-downloader
# 如需支持字体解密功能 (decode_font), 请使用:
# pip install novel-downloader[font-recovery]
# 初始化默认配置 (生成 settings.toml)
novel-cli settings init
# 编辑 ./settings.toml 完成 site/book_ids 等
# 可查看 docs/4-settings-schema.md
# 运行下载
novel-cli download 123456
从 GitHub 安装 (开发版)
如需体验开发中的最新功能, 可通过 GitHub 安装:
git clone https://github.com/BowenZ217/novel-downloader.git
cd novel-downloader
pip install .
# 或安装带可选功能:
# pip install .[font-recovery]
文档结构
项目说明
- 本项目仅供学习和研究使用, 不得用于任何商业或违法用途。请遵守目标网站的 robots.txt 以及相关法律法规。
- 本项目开发者对因使用该工具所引起的任何法律责任不承担任何责任。
- 如果遇到网站结构变化或其他问题, 可能导致程序无法正常工作, 请自行调整代码或寻找其他解决方案。
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
novel_downloader-1.3.3.tar.gz
(157.1 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file novel_downloader-1.3.3.tar.gz.
File metadata
- Download URL: novel_downloader-1.3.3.tar.gz
- Upload date:
- Size: 157.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6964c07364be9a9db20d4f2c955f45ffedb7ae48bf36f316fb555dc8956bb7f3
|
|
| MD5 |
03dc102e33ea94a08c9a1a4687e33e7f
|
|
| BLAKE2b-256 |
7d79ad4402a1578a31da7d9d540541d2ddd03d93695d1d8488ffe026d651ae5b
|
File details
Details for the file novel_downloader-1.3.3-py3-none-any.whl.
File metadata
- Download URL: novel_downloader-1.3.3-py3-none-any.whl
- Upload date:
- Size: 236.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
59746b5c02cc825d82c7fe05386b23b882fe9b7f694d322f7bf2637bb9c09565
|
|
| MD5 |
85a25864acb2775dd47562d927c94d98
|
|
| BLAKE2b-256 |
16eb466e4a30046887d5fd62cb4b1bcdcf24a129f2068add6b1b000168caad73
|