Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FormatGraphStats ¶
FormatGraphStats returns a human-readable stats string.
Types ¶
type Node ¶
type Node struct {
Path string
Language string
Size int64
Imports []string
Symbols []string
References []string
ImportedBy []string
Tags []string
}
Node represents a file in the project graph.
type ProjectGraph ¶
type ProjectGraph struct {
// contains filtered or unexported fields
}
ProjectGraph represents the dependency graph of a project. Inspired by lean-ctx's ctx_graph.
func NewProjectGraph ¶
func NewProjectGraph(rootDir string) *ProjectGraph
NewProjectGraph creates a new project graph.
func (*ProjectGraph) Analyze ¶
func (g *ProjectGraph) Analyze() error
Analyze scans the project and builds the dependency graph.
func (*ProjectGraph) FindRelatedFiles ¶
func (g *ProjectGraph) FindRelatedFiles(path string, maxResults int) []string
FindRelatedFiles finds files related to the given file through dependencies.
func (*ProjectGraph) ImpactAnalysis ¶
func (g *ProjectGraph) ImpactAnalysis(path string) []string
ImpactAnalysis finds all files affected by a change to the given file.
func (*ProjectGraph) Stats ¶
func (g *ProjectGraph) Stats() map[string]any
Stats returns project statistics.
Click to show internal directories.
Click to hide internal directories.