fswrapper

package
v0.0.0-...-69fb7db Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2025 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FSWrapper

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

func NewFSWrapper

func NewFSWrapper() *FSWrapper

func NewMemoryWrapper

func NewMemoryWrapper() *FSWrapper

func (*FSWrapper) CheckImmutable

func (e *FSWrapper) CheckImmutable()

func (*FSWrapper) Open

func (t *FSWrapper) Open(name string) (fs.File, error)

func (*FSWrapper) OpenFile

func (t *FSWrapper) OpenFile(name string, flag int, perm os.FileMode) (io.ReadWriteCloser, error)

func (*FSWrapper) ParseEfivars

func (t *FSWrapper) ParseEfivars(f io.Reader, size int) (attributes.Attributes, *bytes.Buffer, error)

func (*FSWrapper) ReadEfivarsFile

func (t *FSWrapper) ReadEfivarsFile(filename string) (attributes.Attributes, *bytes.Buffer, error)

For a full path instead of the inferred efivars path

func (*FSWrapper) ReadEfivarsWithGuid

func (t *FSWrapper) ReadEfivarsWithGuid(filename string, guid util.EFIGUID) (attributes.Attributes, *bytes.Buffer, error)

func (*FSWrapper) ReadFile

func (t *FSWrapper) ReadFile(name string) ([]byte, error)

func (*FSWrapper) SetFS

func (e *FSWrapper) SetFS(fs afero.Fs)

func (*FSWrapper) UnsetImmutable

func (e *FSWrapper) UnsetImmutable()

func (*FSWrapper) WriteEfivarsWithGuid

func (t *FSWrapper) WriteEfivarsWithGuid(name string, attrs attributes.Attributes, b []byte, guid util.EFIGUID) error

Write an EFI variable to sysfs TODO: Fix retryable writes

func (*FSWrapper) WriteFile

func (t *FSWrapper) WriteFile(name string, data []byte, perm os.FileMode) error

Jump to

Keyboard shortcuts

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