- Add text cleaning to remove page reference numbers (e.g., "10After" -> "After") - Implement cleanHighlightText() function with boundary detection - Add NickelMenu configuration for UI integration - Create sync wrapper scripts (with and without FBInk notifications) - Add installation guides for Kobo deployment - Include pointer/slice explanation examples for learning Features: - Extracts highlights from Kobo SQLite database - Cleans page references from academic texts - Computes SHA-256 hashes for deduplication - POSTs JSON to Flask API endpoint - Supports ARM static linking for Kobo hardware - Optional FBInk notifications for user feedback 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
86 lines
1.9 KiB
Markdown
86 lines
1.9 KiB
Markdown
# Installing kb_exfiltrator on Kobo
|
|
|
|
## Prerequisites
|
|
|
|
1. **NickelMenu** installed on your Kobo (usually comes with KOReader)
|
|
2. SSH access to your Kobo
|
|
3. Kobo connected to WiFi
|
|
|
|
## Installation
|
|
|
|
### 1. Copy files to Kobo
|
|
|
|
```bash
|
|
# Copy the binary
|
|
scp kb_exfiltrator-kobo-arm root@192.168.88.110:/usr/local/bin/kb_exfiltrator
|
|
|
|
# Copy the wrapper script
|
|
scp sync_highlights.sh root@192.168.88.110:/usr/local/bin/sync_highlights.sh
|
|
|
|
# Copy NickelMenu config
|
|
scp nickel_menu_config root@192.168.88.110:/mnt/onboard/.adds/nm/kb_exfiltrator
|
|
```
|
|
|
|
### 2. Set permissions via SSH
|
|
|
|
```bash
|
|
ssh root@192.168.88.110
|
|
|
|
chmod +x /usr/local/bin/kb_exfiltrator
|
|
chmod +x /usr/local/bin/sync_highlights.sh
|
|
```
|
|
|
|
### 3. Update the endpoint URL
|
|
|
|
Edit the script on the Kobo to use your server's IP/hostname:
|
|
|
|
```bash
|
|
vi /usr/local/bin/sync_highlights.sh
|
|
# Change: ENDPOINT="http://192.168.88.69:42070/api/highlights"
|
|
# To your actual server URL
|
|
```
|
|
|
|
### 4. Restart Kobo
|
|
|
|
The NickelMenu config is read on boot, so restart your Kobo:
|
|
```bash
|
|
reboot
|
|
```
|
|
|
|
## Usage
|
|
|
|
After rebooting, you'll see "Sync Highlights" in:
|
|
- Main menu (press the top-left Kobo icon)
|
|
- Reader menu (while reading a book)
|
|
|
|
Tap it to sync your highlights to your server!
|
|
|
|
## Logs
|
|
|
|
Check sync logs at: `/mnt/onboard/.adds/kb_exfiltrator.log`
|
|
|
|
## Manual Usage (via SSH)
|
|
|
|
```bash
|
|
ssh root@192.168.88.110
|
|
/usr/local/bin/kb_exfiltrator /mnt/onboard/.kobo/KoboReader.sqlite http://yourserver:42070/api/highlights
|
|
```
|
|
|
|
## Troubleshooting
|
|
|
|
### Menu item doesn't appear
|
|
- Check `/mnt/onboard/.adds/nm/kb_exfiltrator` exists
|
|
- Restart Kobo
|
|
- Check NickelMenu is installed
|
|
|
|
### Sync fails
|
|
- Check log: `cat /mnt/onboard/.adds/kb_exfiltrator.log`
|
|
- Verify WiFi is connected
|
|
- Test manually via SSH
|
|
- Verify server is running: `curl http://192.168.88.69:42070/`
|
|
|
|
### "No route to host"
|
|
- Kobo WiFi disconnected
|
|
- Server IP changed
|
|
- Edit `/usr/local/bin/sync_highlights.sh` with correct IP
|