Update eyeball plugin with bug fixes and Windows support

- Fix resource leaks (pdf_doc closed in finally blocks)
- Fix Windows Word COM automation (DispatchEx, proper cleanup)
- Fix converter order (Word before LibreOffice on Windows)
- Add source file existence checks with clear errors
- Fix Playwright cache detection for all platforms
- Fix setup.sh error handling (pipefail)
- Fix AppleScript path injection
- Fix highlight padding scaling with DPI
- Add pywin32 as Windows dependency
- Update README with Windows setup instructions

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
dvelton
2026-04-04 17:49:08 -07:00
parent eeb7cb1f30
commit 4626aaf948
3 changed files with 246 additions and 86 deletions

View File

@@ -42,7 +42,12 @@ Before first use, check that dependencies are installed:
python3 <path-to>/eyeball.py setup-check
```
If anything is missing, install the required dependencies:
If anything is missing, run the setup script from the eyeball plugin directory:
```bash
bash <path-to>/setup.sh
```
Or install manually:
```bash
pip3 install pymupdf pillow python-docx playwright
python3 -m playwright install chromium
@@ -57,7 +62,7 @@ Follow these steps exactly. The order matters.
Before writing any analysis, extract and read the full text of the source document:
```bash
python3 <path-to>/eyeball.py extract-text --source "<path-or-url>"
python3 eyeball.py extract-text --source "<path-or-url>"
```
Read the output carefully. Identify actual section numbers, headings, page numbers, and key language.
@@ -113,7 +118,7 @@ RIGHT -- includes the section number for precision, targets the correct page:
Construct a JSON array of sections and call the build command:
```bash
python3 <path-to>/eyeball.py build \
python3 eyeball.py build \
--source "<path-or-url>" \
--output ~/Desktop/<title>.docx \
--title "Analysis Title" \