# Docset Viewer PHP web app for searching and browsing local Zeal/Dash docsets. ## Local setup This project is intended to live under `/root/projects/docset-viewer`, which is served by the local nginx projects web root. 1. Put docset directories in `data/docsets/`. 2. Open the app through local nginx, for example `/docset-viewer/` on the projects host. 3. Search for symbols/functions/classes, then open entries in the embedded document viewer. Docsets are not committed to git. The PHP test docset can be downloaded with: ```bash mkdir -p data/docsets tmp curl -L https://kapeli.com/feeds/PHP.tgz -o tmp/PHP.tgz tar -xzf tmp/PHP.tgz -C data/docsets ``` ## Structure - `views/index.php` - search form and result list. - `views/docsets.php` - installed docset list. - `views/view.php` - app shell around a selected document. - `views/asset.php` - safe docset asset streaming endpoint. - `lib/docset_repository.php` - docset discovery, SQLite search, and path containment checks. - `data/docsets/` - ignored local docset storage. ## Requirements - PHP with `SQLite3`, `SimpleXML`, and `DOM` extensions enabled. - A Dash/Zeal-compatible `*.docset` with `Contents/Resources/docSet.dsidx`. ## Validation ```bash php tests/smoke.php ```