checksum

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2023 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Base64

func Base64(data []byte) string

Base64 simple convert to base64

func DirFiles

func DirFiles(dir, prefix string) ([]string, error)

Types

type GoDirHash

type GoDirHash struct {
	HashSynthesized       string
	HashSynthesizedBase64 string
	GoCheckSum            string
}

GoDirHash is the result of hash

func Hash1

func Hash1(files []string, open func(string) (io.ReadCloser, error)) (GoDirHash, error)

Hash1 `1` means SHA256

func HashDir

func HashDir(dir, prefix string) (GoDirHash, error)

HashDir hash the specify dir

type GoModHash

type GoModHash struct {
	Hash                  string
	HashBase64            string
	HashSynthesized       string
	HashSynthesizedBase64 string
	GoCheckSum            string
}

GoModHash is the result of hash

func HashGoMod

func HashGoMod(goModFile string) (GoModHash, error)

HashGoMod hash the go.mod file

Jump to

Keyboard shortcuts

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