github

package
v1.6.0 Latest Latest
Warning

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

Go to latest
Published: May 25, 2026 License: MIT Imports: 4 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package github provides an output formatter that emits GitHub Actions workflow commands (::error / ::warning / ::notice) so Leakwatch findings show up as inline annotations on pull requests and in the workflow run log.

The format is meant to be written to the Actions runner's stdout: workflow commands are only interpreted on the live command stream, so writing them to a file has no effect. For safety, this formatter NEVER emits the raw secret value — annotations render in the (often public) PR UI and run logs, so only the redacted value is shown regardless of any --show-raw setting.

Reference: https://docs.github.com/actions/using-workflows/workflow-commands-for-github-actions

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Formatter

type Formatter struct{}

Formatter emits findings as GitHub Actions workflow commands.

func (*Formatter) FileExtension

func (f *Formatter) FileExtension() string

FileExtension returns the file extension for this format. Workflow commands are intended for stdout, not a file; ".txt" is returned to satisfy the Formatter contract.

func (*Formatter) Format

func (f *Formatter) Format(w io.Writer, findings []finding.Finding) error

Format writes one workflow command per finding to w. A finding with a known file path is anchored to that file and line so GitHub renders it inline on the "Files changed" view; a finding without a file path becomes a run-level annotation (no file/line properties).

Jump to

Keyboard shortcuts

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