Documentation
¶
Overview ¶
Package list builds a markdown inventory of PHP routes, files and classes.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExpandFiles ¶
ExpandFiles resolves path arguments to a sorted list of PHP file paths. Path forms match Go's package patterns:
- "." or "dir": .php/.phpt files in that directory only (non-recursive)
- "./..." or "dir/...": that directory and all subdirectories
- "file.php": that file
When paths is empty, "." is used.
Types ¶
type PathGroup ¶ added in v0.4.0
PathGroup is the paths of one folder: Dir holds the folder, "." when the paths sit in the run directory, and Indexes the positions of its paths in the input slice, so a caller can carry per-path data alongside without the group copying it.
func GroupByDir ¶ added in v0.4.0
GroupByDir buckets paths by the folder holding them, preserving the order the input established both between folders and inside one. Bucketing is explicit rather than relying on the sort, because sorted paths do not keep a folder contiguous: a/b.php, a/m/x.php and a/z.php interleave.
type Row ¶
type Row struct {
Route string // e.g. "GET /users/{id}", "@startup", or empty
Filename string // slash-separated path relative to the working directory
Classes string // comma-separated FQNs, or empty
}
Row is one markdown table row.