common

package
v1.13.0 Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2025 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindFiles

func FindFiles(includes, excludes []string) (map[string]string, error)

func ProcessFiles

func ProcessFiles[T any](files map[string]string, processor FileProcessor[T]) (map[string]T, error)

func ProcessFilesGlob

func ProcessFilesGlob[T any](includes, excludes []string, processor FileProcessor[T]) (map[string]T, error)

func ReadForgeArtifact

func ReadForgeArtifact(path string) (*solc.ForgeArtifact, error)

func WriteJSON

func WriteJSON(data interface{}, path string) error

Types

type ErrorReporter

type ErrorReporter struct {
	// contains filtered or unexported fields
}

func NewErrorReporter

func NewErrorReporter() *ErrorReporter

func (*ErrorReporter) Fail

func (e *ErrorReporter) Fail(msg string, args ...any)

func (*ErrorReporter) HasError

func (e *ErrorReporter) HasError() bool

type FileProcessor

type FileProcessor[T any] func(path string) (T, []error)

type Void

type Void struct{}

Jump to

Keyboard shortcuts

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