omnidevx

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Jul 19, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package omnidevx collects developer-experience events from GitHub for the OmniDevX domain (github.com/plexusone/omnidevx-core), following the omni-github per-domain package convention alongside omnistorage and omniskill.

Contribution data comes from github.com/grokify/gogithub/profile (GraphQL contribution calendar and per-repository commit statistics), normalized into canonical devx.* events:

  • devx.profile.snapshot — whole-profile period totals
  • devx.contribution.snapshot — per-repository period totals
  • devx.contribution.recorded — daily contribution-calendar counts

GitHub-reported contributions overlap with locally-collected git commits (providers/git in omnidevx-core); the aggregation layer keeps the two sources separate via bySource metrics rather than summing them.

Events carry api-mode provenance: they are observed from the live GitHub API rather than reconstructed from local history.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Collector

type Collector struct {
	// contains filtered or unexported fields
}

Collector reads GitHub contribution data via gogithub/profile.

func New

func New(cfg Config) (*Collector, error)

New returns a Collector for the given config.

func (*Collector) Collect

Collect implements omnidevx.Collector. The request period must be bounded: GitHub's contribution query needs an explicit range, and unbounded scans of account history are rarely intended.

func (*Collector) Source

func (c *Collector) Source() core.Source

Source implements omnidevx.Collector.

type Config

type Config struct {
	// Token is a GitHub API token. Required unless both clients are set.
	Token string

	// Username is the GitHub account whose contributions are collected.
	// Required.
	Username string

	// RESTClient overrides the token-derived REST client (for testing or
	// custom transports).
	RESTClient *github.Client

	// GraphQLClient overrides the token-derived GraphQL client.
	GraphQLClient *githubv4.Client
}

Config holds configuration for the GitHub DevX collector.

Jump to

Keyboard shortcuts

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