Documentation
¶
Index ¶
- Constants
- Variables
- func ParseCargoToml(content string) []parsed
- func ParseGoMod(content string) []parsed
- func VersionOutdated(current, latest string) bool
- type CommitHeatmap
- type ContribEntry
- type DebtStat
- type DepEntry
- type GeoEntry
- type HealthFiles
- type LangEntry
- type NewcomerStat
- type Options
- type PRStat
- type Progress
- type ReleaseEntry
- type RepoSummary
- type SignalStat
- type StickinessStat
Constants ¶
View Source
const ( ModuleLanguages = "Languages" ModuleContributors = "Contributors" ModuleGeo = "Star Geography" ModuleCommitStats = "Commit Activity" ModuleHeatmap = "Commit Heatmap" ModuleReleases = "Releases" ModuleBusFactor = "Bus Factor" ModuleCommunity = "Community Files" ModuleDebt = "Issue Debt" ModuleNewcomer = "Labels" ModuleDeps = "Dependencies" ModulePRs = "Pull Requests" ModuleSignals = "Signals" )
Module names used for progress reporting.
Variables ¶
View Source
var ModuleOrder = []string{ ModuleLanguages, ModuleContributors, ModuleGeo, ModuleCommitStats, ModuleHeatmap, ModuleReleases, ModuleBusFactor, ModuleCommunity, ModuleDebt, ModuleNewcomer, ModulePRs, ModuleSignals, ModuleDeps, }
ModuleOrder is the display order for the loading screen.
Functions ¶
func ParseCargoToml ¶
func ParseCargoToml(content string) []parsed
func ParseGoMod ¶
func ParseGoMod(content string) []parsed
func VersionOutdated ¶
versionOutdated returns true if latest is strictly newer than current. Does a simple major-version check — good enough for highlighting stale deps.
Types ¶
type CommitHeatmap ¶
type CommitHeatmap [7][24]int
CommitHeatmap is indexed [weekday][hour], time.Sunday == 0.
type ContribEntry ¶
type HealthFiles ¶
type NewcomerStat ¶
func CalcNewcomer ¶
func CalcNewcomer(labels []string) NewcomerStat
type PRStat ¶
type PRStat struct {
Open int
MergeRate float64 // % of closed PRs that were merged
AvgMergeDays float64
Merged30d int
Rejected30d int
}
func CalcPRStats ¶
func CalcPRStats(prs []*github.PullRequest, openCount int) PRStat
type ReleaseEntry ¶
type RepoSummary ¶
type RepoSummary struct {
Owner string
Repo string
Description string
Stars int
Forks int
Watchers int
OpenIssues int
License string
Topics []string
CreatedAt time.Time
UpdatedAt time.Time
IsArchived bool
DefaultBranch string
Languages []LangEntry
Contributors []ContribEntry
StarsByGeo []GeoEntry
CommitActivity []int
CommitHeatmap CommitHeatmap
Releases []ReleaseEntry
BusFactor int
TotalCommits int
Stickiness StickinessStat
HealthFiles HealthFiles
Debt DebtStat
Deps []DepEntry
Newcomer NewcomerStat
PRs PRStat
Signals SignalStat
}
type SignalStat ¶
type SignalStat struct {
HasCI bool
CIName string
HasTests bool
ActiveForks int
StarsThisWeek int
AvgWeeklyStars float64
Trending string // "rising", "stable", "declining"
}
func CalcSignals ¶
func CalcSignals( hasWorkflows, hasCircleCI, hasTravis bool, hasTests bool, forks []*gogithub.Repository, recentStars []*gogithub.Stargazer, totalStars int, createdAt time.Time, ) SignalStat
type StickinessStat ¶
func CalcStickiness ¶
func CalcStickiness(contributors []ContribEntry) StickinessStat
Click to show internal directories.
Click to hide internal directories.