Documentation
¶
Index ¶
Constants ¶
View Source
const ( Reset = "\033[0m" Red = "\033[31m" Green = "\033[32m" Yellow = "\033[33m" Blue = "\033[34m" Magenta = "\033[35m" Cyan = "\033[36m" Gray = "\033[37m" White = "\033[97m" )
Color codes
Variables ¶
This section is empty.
Functions ¶
func AutoFixRepository ¶
AutoFixRepository tries to match and replace third-party action references with SHA It uses SHA resolution to find accurate SHA
Types ¶
type GitRepository ¶
type GitRepository struct {
// contains filtered or unexported fields
}
GitRepository implements Repository interface
func ListRepositoriesAtRoot ¶ added in v1.1.3
func ListRepositoriesAtRoot(root FilePath) ([]*GitRepository, error)
func (GitRepository) ListBranches ¶
func (g GitRepository) ListBranches(fp FilePath) ([]string, error)
func (GitRepository) Name ¶
func (g GitRepository) Name() string
type Inventory ¶
type Inventory struct {
Records []*InventoryRecord `json:"findings"`
}
Inventory aggregates multiple inventory records.
func AuditRepository ¶
AuditRepository collects inventory details from current Git repository.
func ScanBranch ¶ added in v1.1.3
ScanBranch scans a given branch for mutable references
type InventoryRecord ¶
type InventoryRecord struct {
Repository string `json:"repository_name"` // Repository name or path
Branch string `json:"branch_name"` // Branch name
FilePath string `json:"actions_file"` // File path where the match was found
Matches []string `json:"matches"` // Regex match results from the file content
}
InventoryRecord holds details for a regex match in a file.
Click to show internal directories.
Click to hide internal directories.