embedded

package
v0.10.2 Latest Latest
Warning

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

Go to latest
Published: Jun 3, 2026 License: MIT Imports: 8 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FS

func FS() embed.FS

FS returns the underlying embed.FS

func InstallSudoers added in v0.10.0

func InstallSudoers(host SudoersInstaller) error

InstallSudoers installs the embedded sudoers file if it is not already installed with the expected content. This may prompt for a sudo password.

func Read

func Read(file string) ([]byte, error)

Read reads the content of file

func ReadString

func ReadString(file string) (string, error)

ReadString reads the content of file as string

func SudoersInstalled added in v0.10.0

func SudoersInstalled() bool

SudoersInstalled checks if the sudoers file contains the expected embedded content.

Types

type SudoersInstaller added in v0.10.0

type SudoersInstaller interface {
	RunInteractive(args ...string) error
	RunWith(stdin io.Reader, stdout io.Writer, args ...string) error
}

SudoersInstaller provides the ability to run commands on the host for installing the sudoers file.

Jump to

Keyboard shortcuts

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