diff options
| author | Paul Buetow <paul@buetow.org> | 2025-08-31 15:15:50 +0300 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2025-08-31 15:15:50 +0300 |
| commit | 114379d591fbbf6afeb649521be0a1aab2bbd3aa (patch) | |
| tree | 6a9d206b375b518c7cf6de70f0733630eafcfbcd /README.md | |
| parent | c508f9b24be667d5d078034b4d4e7bb07b28da69 (diff) | |
Implement REVIEW.md suggestions:\n- Simplify gemfeed detection in Aggregator\n- Make log globs configurable for Logreader\n- Remove debug-only imports; add comments\n- Add HTML::Entities usage; document deps\n- Add tests under t/ and make script require-safe\n- Add .perltidyrc and Justfile; add dev tasks\n- Update README and REVIEW with changes
Diffstat (limited to 'README.md')
| -rw-r--r-- | README.md | 28 |
1 files changed, 27 insertions, 1 deletions
@@ -17,9 +17,19 @@ A privacy-respecting web analytics tool for OpenBSD that processes HTTP/HTTPS an On OpenBSD, install dependencies: ```sh -doas pkg_add p5-Digest-SHA3 p5-PerlIO-gzip p5-JSON p5-String-Util p5-LWP-Protocol-https +doas pkg_add p5-Digest-SHA3 p5-PerlIO-gzip p5-JSON p5-String-Util p5-LWP-Protocol-https p5-HTML-Parser perltidy ``` +## Dependencies + +- Perl 5.38+ +- Core: `Time::Piece`, `Getopt::Long`, `Sys::Hostname`, `File::Basename` +- CPAN/Packages: `Digest::SHA3`, `PerlIO::gzip`, `JSON`, `String::Util`, `LWP::UserAgent` (and HTTPS support), `HTML::Entities` + +Notes: +- On OpenBSD the packages are: `p5-Digest-SHA3`, `p5-PerlIO-gzip`, `p5-JSON`, `p5-String-Util`, `p5-LWP-Protocol-https`, `p5-HTML-Parser` (provides `HTML::Entities`). +- The script expects Perl 5.38 features; adjust accordingly if running older Perl. + ## Usage ### Basic Operations @@ -129,3 +139,19 @@ Reports include: ## License BSD 3-Clause License (see LICENSE file) +## Testing + +Basic test suite using Test::More is included under `t/`. + +- Run all tests: `prove -lr t` +- The script now avoids running its CLI when loaded via `require`, enabling unit testing of internal packages. + +## Development + +- Format: `just format` (uses `.perltidyrc`, requires `perltidy`) +- Test: `just test` (uses `prove` if available, otherwise runs tests via `perl`) +- Lint/syntax: `just check` +- Cleanup: `just clean` +- Generate reports (from repo's `stats/`): `just reports` + +Tip: install `just` (a command runner) for convenience. |
