dogfood

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package dogfood implements the nSelf dogfood audit system for production health verification.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SaveReport

func SaveReport(projectDir string, report *AuditReport) error

SaveReport writes the audit report as JSON to the project's .nself directory.

Types

type AuditCheck

type AuditCheck struct {
	Name    string `json:"name"`
	Status  string `json:"status"` // pass, fail, warn, skip
	Message string `json:"message"`
	Section string `json:"section"`
}

AuditCheck represents a single dogfood audit check.

type AuditReport

type AuditReport struct {
	ID        string       `json:"id"`
	RanAt     time.Time    `json:"ran_at"`
	Checks    []AuditCheck `json:"checks"`
	PassCount int          `json:"pass_count"`
	FailCount int          `json:"fail_count"`
	WarnCount int          `json:"warn_count"`
	SkipCount int          `json:"skip_count"`
}

AuditReport holds the complete dogfood audit results.

func GetLatestReport

func GetLatestReport(projectDir string) (*AuditReport, error)

GetLatestReport reads the most recent audit report.

func GetReportsSince

func GetReportsSince(projectDir string, since time.Time) ([]*AuditReport, error)

GetReportsSince returns all reports since the given time.

func RunAudit

func RunAudit(ctx context.Context, projectDir string) *AuditReport

RunAudit executes all 21 dogfood checks against the current environment.

Jump to

Keyboard shortcuts

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