Documentation
¶
Overview ¶
Package parse turns raw input (a file, stdin, or the environment) into a Blob: the original text plus a flattened key/value view and any structured form (JSON object, INI sections). Recognizers consume the Blob.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Blob ¶
type Blob struct {
Raw string
File string
Kind module.SourceKind
ModTime time.Time // source file mtime (zero if unknown: stdin/env/harvested)
Vars map[string]string // flattened key=value (env, dotenv, all INI keys)
Lines map[string]int // 1-based source line per variable name (when known)
JSON map[string]any // populated if the whole blob is a JSON object
INI []INISection
// Fingerprint is an upstream scanner's stable id for this finding, carried
// through untouched so that scanner's own viewer can dedupe geiger's output
// against its own. Empty unless the blob came from such a report.
Fingerprint string
}
Blob is the parsed view of one input source.
type INISection ¶
INISection is one [section] of an INI file with its keys.
Click to show internal directories.
Click to hide internal directories.