models

package
v0.4.3 Latest Latest
Warning

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

Go to latest
Published: Jul 27, 2026 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BranchNode

type BranchNode struct {
	Name           string
	SHA            string
	Ahead          int
	Behind         int
	LastCommitDate time.Time
	Parent         *BranchNode
	Children       []*BranchNode
}

BranchNode represents a node in the branch tree.

func (*BranchNode) AddChild

func (n *BranchNode) AddChild(child *BranchNode)

AddChild adds a child node to this branch.

func (*BranchNode) Depth

func (n *BranchNode) Depth() int

Depth returns the depth of this node in the tree.

func (*BranchNode) IsLeaf

func (n *BranchNode) IsLeaf() bool

IsLeaf returns true if this node has no children.

type Repository

type Repository struct {
	Owner string
	Name  string
}

Repository represents a GitHub repository reference.

func ParseRepository

func ParseRepository(repo string) (*Repository, error)

ParseRepository parses a repository string into owner and name.

func (Repository) FullName

func (r Repository) FullName() string

FullName returns the full repository name (owner/name).

Jump to

Keyboard shortcuts

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