介绍
# reMarkable Cloud
通过云 API 将文档和网页文章发送到 reMarkable 平板。使用 `rmapi` 进行云端访问。
## 设置
安装 rmapi(需要 Go): ```bash cd /tmp && git clone --depth 1 https://github.com/ddvk/rmapi.git cd rmapi && go build -o /usr/local/bin/rmapi . ```
首次运行将提示输入来自 https://my.remarkable.com/device/browser?showOtp=true 的一次性代码。
Python 依赖项(用于文章转换):`readability-lxml`、`ebooklib`、`requests`、`beautifulsoup4`、`lxml`。
## 命令
### 发送网页文章到设备
```bash {baseDir}/scripts/remarkable.sh send-article --url "https://example.com/article" --dir /Articles {baseDir}/scripts/remarkable.sh send-article --url "https://example.com/article" --format pdf --dir / {baseDir}/scripts/remarkable.sh send-article --url "https://example.com/article" --title "Custom Title" --dir /Articles ```
获取文章,提取可读内容,转换为 EPUB(默认)或 PDF,上传到 reMarkable 云端。设备会自动同步。
### 列出文件
```bash {baseDir}/scripts/remarkable.sh ls / {baseDir}/scripts/remarkable.sh ls /Articles {baseDir}/scripts/remarkable.sh ls "/Book Notes" ```
输出:`[f]` = 文件,`[d]` = 目录。
### 上传文件
```bash {baseDir}/scripts/remarkable.sh upload --file /path/to/document.pdf --dir /Books {baseDir}/scripts/remarkable.sh upload --file /path/to/book.epub --dir / ```
### 创建文件夹
```bash {baseDir}/scripts/remarkable.sh mkdir --path /NewFolder ```
### 搜索文件
```bash {baseDir}/scripts/remarkable.sh find --name "article title" ```
## 注意事项
- 建议文章使用 EPUB 格式 —— 在电子墨水屏上重排效果良好 - 设备连接到 WiFi 时会自动同步 - 认证令牌由 rmapi 缓存在 `~/.rmapi` - 某些网站会阻止爬取 —— 如果文章获取失败,请尝试其他 URL