reader

package
v0.0.0-...-bf3ae02 Latest Latest
Warning

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

Go to latest
Published: Dec 10, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Read

func Read(config *Config) (ps []*packages.Package, err error)

Read reads a project and all its packages and files.

Types

type Config

type Config struct {
	// Verbose indicates that the parse logs
	// should be written to the standard out.
	Verbose bool

	// Dir is the path to the main package or primary package.
	// The path should contain the mod file.
	// The path follows the standard patter for go tools.
	Dir string

	// Patterns is the patterns to load the packages with.
	Patterns []string

	// Context is the optional context to cancel a build with.
	Context context.Context

	// BuildFlags are the optional build flags to build with.
	// Example: // +build tag_name
	BuildFlags []string
}

Config is the read and parse configuration.

Jump to

Keyboard shortcuts

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