git

package
v1.4.310 Latest Latest
Warning

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

Go to latest
Published: Sep 11, 2025 License: MIT Imports: 11 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Commit

type Commit struct {
	SHA       string
	Message   string
	Author    string
	Email     string
	Date      time.Time
	IsMerge   bool
	PRNumber  int
	IsVersion bool
	Version   string
}

type Version

type Version struct {
	Name      string
	Date      time.Time
	CommitSHA string
	Commits   []*Commit
	PRNumbers []int
	AISummary string
}

type Walker

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

func NewWalker

func NewWalker(repoPath string) (*Walker, error)

func (*Walker) AddFile added in v1.4.262

func (w *Walker) AddFile(filename string) error

AddFile adds a file to the git index

func (*Walker) CommitChanges added in v1.4.262

func (w *Walker) CommitChanges(message string) (plumbing.Hash, error)

CommitChanges creates a commit with the given message

func (*Walker) GetLatestTag

func (w *Walker) GetLatestTag() (string, error)

GetLatestTag returns the name of the most recent tag by committer date

func (*Walker) GetRepoInfo

func (w *Walker) GetRepoInfo() (owner string, name string, err error)

func (*Walker) GetStatusDetails added in v1.4.262

func (w *Walker) GetStatusDetails() (string, error)

GetStatusDetails returns a detailed status of the working directory

func (*Walker) IsWorkingDirectoryClean added in v1.4.262

func (w *Walker) IsWorkingDirectoryClean() (bool, error)

IsWorkingDirectoryClean checks if the working directory has any uncommitted changes

func (*Walker) PushToRemote added in v1.4.262

func (w *Walker) PushToRemote() error

PushToRemote pushes the current branch to the remote repository It automatically detects GitHub repositories and uses token authentication when available

func (*Walker) RemoveFile added in v1.4.262

func (w *Walker) RemoveFile(filename string) error

RemoveFile removes a file from both the working directory and git index

func (*Walker) Repository added in v1.4.262

func (w *Walker) Repository() *git.Repository

Repository returns the underlying git repository

func (*Walker) WalkCommitsSinceTag

func (w *Walker) WalkCommitsSinceTag(tagName string) (*Version, error)

WalkCommitsSinceTag walks commits from the specified tag to HEAD and returns only "Unreleased" version

func (*Walker) WalkHistory

func (w *Walker) WalkHistory() (map[string]*Version, error)

func (*Walker) WalkHistorySinceTag added in v1.4.247

func (w *Walker) WalkHistorySinceTag(sinceTag string) (map[string]*Version, error)

WalkHistorySinceTag walks git history from HEAD down to (but not including) the specified tag and returns any version commits found along the way

func (*Walker) Worktree added in v1.4.262

func (w *Walker) Worktree() (*git.Worktree, error)

Worktree returns the git worktree for performing git operations

Jump to

Keyboard shortcuts

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