无需浏览器,可直接在服务器上运行脚本,自动阅读Linuxdo论坛帖子,支持多账户登录。
## 自动阅读与点赞工具**仓库:** (https://github.com/14790897/auto-read-liunxdo) **记得点个 Star!**
### 使用方法:
1. **油猴脚本:** 在 `index_passage_list` 中获取脚本代码,推荐使用 (https://greasyfork.org/en/scripts/489464-auto-read)。
2. **Puppeteer 无头运行:**
- 设置环境变量: 在 `.env` 中设置用户名和密码。
- 运行:
- Windows:
```sh
npm install
node .\pteer.js
```
- Linux:安装必要的包并运行相同命令。
```sh
sudo apt-get update
sudo apt install nodejs npm -y
sudo apt-get install -y wget unzip fontconfig locales gconf-service libasound2 libatk1.0-0 libc6 libcairo2 libcups2 libdbus-1-3 libexpat1 libfontconfig1 libgcc1 libgconf-2-4 libgdk-pixbuf2.0-0 libglib2.0-0 libgtk-3-0 libnspr4 libpango-1.0-0 libpangocairo-1.0-0 libstdc++6 libx11-6 libx11-xcb1 libxcb1 libxcomposite1 libxcursor1 libxdamage1 libxext6 libxfixes3 libxi6 libxrandr2 libxrender1 libxss1 libxtst6 ca-certificates fonts-liberation libappindicator1 libnss3 lsb-release xdg-utils wget
```
3. **GitHub Action 自动阅读:** 每天 0 点自动阅读 (可修改时间和持续时间,代码位于 `.github/workflows/cron_read.yaml`)
- Fork 仓库。
- 设置环境变量: 在 GitHub Action 的 secrets 中设置用户名和密码 (变量名参考 `.env` 中的设置)。
- 启动 workflow。
- 教程: (https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web?tab=readme-ov-file#enable-automatic-updates)
[观看视频演示](//player.bilibili.com/player.html?aid=1052508927&bvid=BV1YH4y1J7Vg&cid=1493292834&p=1)
**成果展示:**
[图片展示](https://linux.do/uploads/default/original/3X/8/2/827e29d024fe2b29b5faa396f167014cc6ef3fa8.png)
页:
[1]