file

package
v0.1.26 Latest Latest
Warning

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

Go to latest
Published: Jan 1, 2022 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	InjectPrefix = prefix + "INJECT"

	IgnorePattern = prefix + "IGNORE" + suffix
)

Variables

This section is empty.

Functions

func Inject added in v0.1.25

func Inject(fl *File, content map[string]string) error

func ReplaceSections

func ReplaceSections(fl *File, tgt filesystem.FileLoader) error

Types

type File

type File struct {
	Path    []string    `json:"path,omitempty"`
	Name    string      `json:"name"`
	Mode    os.FileMode `json:"mode,omitempty"`
	Content string      `json:"-"`
}

func NewFile

func NewFile(path string, mode os.FileMode, b []byte, logger *zap.SugaredLogger) *File

func (*File) FullPath

func (f *File) FullPath() string

type Files

type Files []*File

func (Files) Exists

func (f Files) Exists(path string) bool

func (Files) Get

func (f Files) Get(path string) *File

func (Files) String

func (f Files) String() string

Jump to

Keyboard shortcuts

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