report

package
v0.25.9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 16, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Overview

Package report renders a terminal dashboard from a thefeed server's hourly DNS reports. It serves nothing on the network: it reads the server's rotating report file (`<data-dir>/dns_hourly.jsonl`), or stdin, and optionally the chat bbolt file for a live account count. It mirrors the aggregations of scripts/thefeed_log_report.py and adds chat stats + bars.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseTimeArg

func ParseTimeArg(s string) (t time.Time, dateOnly bool, err error)

ParseTimeArg parses a --report-from/--report-to value as UTC. Accepted: "2006-01-02", "2006-01-02 15:04", or RFC3339. dateOnly reports whether the value named a bare date, so a range end can be widened to cover that day.

func Run

func Run(opts Options) error

Run renders the dashboard once, or live on a ticker until interrupted.

Types

type Options

type Options struct {
	Path    string        // report JSONL path, or "-" for stdin
	ChatDB  string        // optional chat bbolt path for a live account count
	Top     int           // number of top channels to show (0 → 15)
	Refresh time.Duration // 0 = render once; >0 = redraw every interval
	From    time.Time     // include only reports at/after this time (zero = all)
	To      time.Time     // include only reports at/before this time (zero = all)
	Out     io.Writer     // defaults to os.Stdout
}

Options configures Run.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL