goembed

package
v1.0.10 Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2026 License: Apache-2.0 Imports: 11 Imported by: 0 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 CheckPath

func CheckPath(pkgDir, abs string, dirOK map[string]bool) (info fs.FileInfo, rel string, err error)

func FileImportsEmbed

func FileImportsEmbed(file *ast.File) bool

func IsBadName

func IsBadName(name string) bool

func ParseDirective

func ParseDirective(line string) (args string, ok bool)

func ParsePatterns

func ParsePatterns(docs ...*ast.CommentGroup) (patterns []string, hasDirective bool, err error)

func RelPath

func RelPath(pkgDir, abs string) (string, error)

func SplitArgs

func SplitArgs(s string) ([]string, error)

func ValidPattern

func ValidPattern(pattern string) bool

Types

type FileData

type FileData struct {
	Name string
	Data []byte
}

func BuildFSEntries

func BuildFSEntries(files []FileData) []FileData

func ResolvePatterns

func ResolvePatterns(pkgDir string, patterns []string) ([]FileData, error)

type VarData

type VarData struct {
	Files []FileData
}

type VarMap

type VarMap map[string]VarData

func LoadDirectives

func LoadDirectives(fset *token.FileSet, files []*ast.File) (VarMap, error)

Jump to

Keyboard shortcuts

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