Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Detect ¶
func Detect(dir string) capability.CapabilitySet
Detect scans PHP source files in dir and returns the combined capability set.
Types ¶
type Adapter ¶
type Adapter struct{}
Adapter implements the Analyzer interface for PHP projects.
type ComposerPackage ¶
type ComposerPackage struct {
Name string
Version string
Dir string // path to vendor/<vendor>/<package>
Dependencies []string
Direct bool
}
ComposerPackage represents a PHP package extracted from composer.lock.
func Load ¶
func Load(dir string) (pkgs []ComposerPackage, retErr error)
Load parses composer.lock in dir and returns the resolved packages. Packages are looked up in vendor/ for source scanning. Load never panics; it returns a structured error on failure. A missing "packages" key returns an empty slice, not an error.
Click to show internal directories.
Click to hide internal directories.