Skip to content

Commit

Permalink
chore: regenerate docs
Browse files Browse the repository at this point in the history
  • Loading branch information
ecshreve committed Mar 4, 2022
1 parent 6b5881d commit 910eefc
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 26 deletions.
8 changes: 5 additions & 3 deletions pkg/format/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,13 +77,13 @@ type HTMLTable struct{}
func (h HTMLTable) Report(w io.Writer, findings []report.Finding) error
```

## type [JSON](<https://github.com/brittonhayes/pillager/blob/main/pkg/format/report.go#L18>)
## type [JSON](<https://github.com/brittonhayes/pillager/blob/main/pkg/format/report.go#L19>)

```go
type JSON struct{}
```

### func \(JSON\) [Report](<https://github.com/brittonhayes/pillager/blob/main/pkg/format/report.go#L20>)
### func \(JSON\) [Report](<https://github.com/brittonhayes/pillager/blob/main/pkg/format/report.go#L21>)

```go
func (j JSON) Report(w io.Writer, findings []report.Finding) error
Expand All @@ -101,7 +101,9 @@ type Markdown struct{}
func (m Markdown) Report(w io.Writer, findings []report.Finding) error
```

## type [Reporter](<https://github.com/brittonhayes/pillager/blob/main/pkg/format/report.go#L14-L16>)
## type [Reporter](<https://github.com/brittonhayes/pillager/blob/main/pkg/format/report.go#L15-L17>)

Reporter is the interface that each of the canonical output formats implement\.

```go
type Reporter interface {
Expand Down
28 changes: 16 additions & 12 deletions pkg/hunter/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import "github.com/brittonhayes/pillager/pkg/hunter"
```

Package hunter contains secret hunting and file scanning tools
Package hunter contains secret hunting and file scanning tools\.

## Index

Expand All @@ -28,7 +28,7 @@ Package hunter contains secret hunting and file scanning tools
- [func (h *Hunter) Report(w io.Writer, findings []report.Finding) error](<#func-hunter-report>)


## type [Config](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L22-L33>)
## type [Config](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L21-L32>)

Config takes all of the configurable parameters for a Hunter\.

Expand All @@ -47,67 +47,71 @@ type Config struct {
}
```

### func [NewConfig](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L37>)
### func [NewConfig](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L38>)

```go
func NewConfig(opts ...ConfigOption) *Config
```

NewConfig creates a Config instance\.

## type [ConfigOption](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L35>)

ConfigOption is a convenient type alias for func\(\*Config\)\.

```go
type ConfigOption func(*Config)
```

### func [WithFS](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L72>)
### func [WithFS](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L73>)

```go
func WithFS(fs afero.Fs) ConfigOption
```

### func [WithFormat](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L112>)
### func [WithFormat](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L113>)

```go
func WithFormat(reporter format.Reporter) ConfigOption
```

### func [WithGitleaksConfig](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L132>)
### func [WithGitleaksConfig](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L133>)

```go
func WithGitleaksConfig(g config.Config) ConfigOption
```

### func [WithLogLevel](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L84>)
### func [WithLogLevel](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L85>)

```go
func WithLogLevel(level string) ConfigOption
```

### func [WithRedact](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L106>)
### func [WithRedact](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L107>)

```go
func WithRedact(redact bool) ConfigOption
```

### func [WithScanPath](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L78>)
### func [WithScanPath](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L79>)

```go
func WithScanPath(path string) ConfigOption
```

### func [WithTemplate](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L125>)
### func [WithTemplate](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L126>)

```go
func WithTemplate(template string) ConfigOption
```

### func [WithVerbose](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L94>)
### func [WithVerbose](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L95>)

```go
func WithVerbose(verbose bool) ConfigOption
```

### func [WithWorkers](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L100>)
### func [WithWorkers](<https://github.com/brittonhayes/pillager/blob/main/pkg/hunter/config.go#L101>)

```go
func WithWorkers(count int) ConfigOption
Expand Down
28 changes: 17 additions & 11 deletions pkg/rules/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import "github.com/brittonhayes/pillager/pkg/rules"
```

Package rules enables the parsing of Gitleaks rulesets
Package rules enables the parsing of Gitleaks rulesets\.

## Index

Expand All @@ -22,14 +22,16 @@ Package rules enables the parsing of Gitleaks rulesets

## Constants

ErrReadConfig is the custom error message used if an error is encountered reading the gitleaks config\.

```go
const (
ErrReadConfig = "Failed to read config"
)
const ErrReadConfig = "Failed to read gitleaks config"
```

## Variables

These strings contain default configs\. They are initialized at compile time via go:embed\.

```go
var (
//go:embed rules_simple.toml
Expand All @@ -40,21 +42,23 @@ var (
)
```

## type [Loader](<https://github.com/brittonhayes/pillager/blob/main/pkg/rules/rules.go#L25-L27>)
## type [Loader](<https://github.com/brittonhayes/pillager/blob/main/pkg/rules/rules.go#L27-L29>)

Loader represents a gitleaks config loader\.

```go
type Loader struct {
// contains filtered or unexported fields
}
```

### func [NewLoader](<https://github.com/brittonhayes/pillager/blob/main/pkg/rules/rules.go#L33>)
### func [NewLoader](<https://github.com/brittonhayes/pillager/blob/main/pkg/rules/rules.go#L35>)

```go
func NewLoader(opts ...LoaderOption) *Loader
```

NewLoader creates a configuration loader\.
NewLoader creates a Loader instance\.

### func \(\*Loader\) [Load](<https://github.com/brittonhayes/pillager/blob/main/pkg/rules/rules.go#L58>)

Expand All @@ -64,27 +68,29 @@ func (l *Loader) Load() config.Config

Load parses the gitleaks configuration\.

### func \(\*Loader\) [WithStrict](<https://github.com/brittonhayes/pillager/blob/main/pkg/rules/rules.go#L48>)
### func \(\*Loader\) [WithStrict](<https://github.com/brittonhayes/pillager/blob/main/pkg/rules/rules.go#L49>)

```go
func (l *Loader) WithStrict() LoaderOption
```

WithStrict enables more strict pillager scanning\.

## type [LoaderOption](<https://github.com/brittonhayes/pillager/blob/main/pkg/rules/rules.go#L29>)
## type [LoaderOption](<https://github.com/brittonhayes/pillager/blob/main/pkg/rules/rules.go#L32>)

LoaderOption sets a parameter for the gitleaks config loader\.

```go
type LoaderOption func(*Loader)
```

### func [FromFile](<https://github.com/brittonhayes/pillager/blob/main/pkg/rules/rules.go#L69>)
### func [FromFile](<https://github.com/brittonhayes/pillager/blob/main/pkg/rules/rules.go#L68>)

```go
func FromFile(file string) LoaderOption
```

FromFile decodes the configuration from a local file\.
FromFile decodes a gitleaks config from a local file\.



Expand Down

0 comments on commit 910eefc

Please sign in to comment.