Documentation
¶
Overview ¶
Package analytics is a tiny PostHog wrapper for the codag CLI.
Defaults: enabled. Opt out with CODAG_TELEMETRY=0 or `codag config set telemetry off`. distinct_id is a random UUID persisted in ~/.config/codag/config.json (CLIDistinctID) on first invocation; this keeps installs anonymous but stable across runs.
Every event auto-tags source=cli, codag_version, os, arch so it joins cleanly with console/website/server events in the same PostHog project.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Capture ¶
Capture fires an event with the standard set of super-properties merged in. No-op when the client is disabled.
func Identify ¶
Identify links the anonymous CLI distinct_id to a server user id once the user signs in via `codag auth login`. After this call, future events from this machine show up on the same person profile as console/server events for the same user.
Types ¶
This section is empty.