All notable changes to this project are documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
0.8.0 - 2026-08-14
- Full environment-variable configuration for every flag via
SERVE_*(withPORTstill honored for Heroku-style deployments). - Structured logging with
log/slog, configurable via--log-format(text/json) and--log-level(debug/info/warn/error). - Health-check endpoint at
/healthz(configurable with--health-path, empty to disable); it bypasses auth and logging for probes. --dirlistingto opt into an automatic file listing for directories without anindex.html; directory listing is disabled by default.- Dotfiles (e.g.
.env,.git) are now hidden from access and directory listings by default; opt in with--all. - BasicAuth users file now supports bcrypt password hashes in addition to plaintext, and secrets may contain colons.
- Configurable CORS origin via
--cors-origin. - Graceful shutdown: the server drains in-flight connections on
SIGINT/SIGTERM. - Functional options for the library API (
WithDirectory,WithPrefix,WithHiddenFiles,WithDirectoryListing). --versionflag, richer version output (Go toolchain and VCS revision), and a DockerHEALTHCHECK.
- Requires Go 1.26.
- Request logging now captures every response, including
401and500s. - Panics return a generic
500to clients; details are logged server-side only. - BasicAuth passwords are compared in constant time.
- Static files are served through
io/fs(os.DirFS) for safer path handling.
- The internal
mockHTTP server package and theHTTPServerinterface indirection, replaced by real integration tests. - The
serve.Optionsstruct, replaced by functional options.