options

package
v0.3.3 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2026 License: Apache-2.0 Imports: 4 Imported by: 2 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

Index

Constants

This section is empty.

Variables

View Source
var Default = Options{
	Algorithms: []intoto.HashAlgorithm{
		intoto.AlgorithmSHA1,
		intoto.AlgorithmSHA256,
	},
	Processors: []string{"hash"},
}

Functions

This section is empty.

Types

type Function

type Function func(*Options) error

func WithAlgorithms

func WithAlgorithms(algos []intoto.HashAlgorithm) Function

func WithFileProcessor

func WithFileProcessor(id string) Function

func WithFilesystem

func WithFilesystem(filesystem fs.FS) Function

func WithIgnorePatterns

func WithIgnorePatterns(patterns []string) Function

func WithNoGitIgnore

func WithNoGitIgnore() Function

func WithPath

func WithPath(path string) Function

type Options

type Options struct {
	Filesystem     fs.FS                  // Filesystem to index
	NoGitignore    bool                   // Do not attempt to read the gitignore file
	IgnorePatterns []string               // Patterns to ignore when scanning file
	Algorithms     []intoto.HashAlgorithm // Algorithms to use when hashing
	Processors     []string               // Identifiers of file processors
}

Jump to

Keyboard shortcuts

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