hash

package
v2.0.5 Latest Latest
Warning

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

Go to latest
Published: Feb 25, 2026 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Run

func Run(opts ...Option) error

Run computes hashes of files or stdin.

Types

type Config

type Config struct {
	Algorithm string
	HMACKey   string
	Files     []string
	Stdout    io.Writer
}

Config holds configuration for the hash command.

type Option

type Option func(*Config)

Option configures a Config.

func WithAlgorithm

func WithAlgorithm(algo string) Option

func WithFiles

func WithFiles(files []string) Option

func WithHMACKey

func WithHMACKey(key string) Option

func WithStdout

func WithStdout(w io.Writer) Option

Jump to

Keyboard shortcuts

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