git

package
v4.7.1 Latest Latest
Warning

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

Go to latest
Published: Nov 9, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetOriginUrl added in v4.6.0

func GetOriginUrl(dir string) (string, error)

func GetRepoShortName added in v4.6.0

func GetRepoShortName(url string) string

func GetStatus added in v4.6.0

func GetStatus(dir string) (gitm.NameStatus, error)

Types

type Branch

type Branch struct {
	Name          string
	LastUpdatedAt *time.Time
	LastCommitMsg *string
	CommitsAhead  int
	CommitsBehind int
	IsCheckedOut  bool
	Remotes       []string
}

type Repo

type Repo struct {
	gitm.Repository
	Origin         string
	Remotes        []string
	Branches       []Branch
	HeadBranchName string
	Status         gitm.NameStatus
}

Extends git.Repository

func FetchRepo added in v4.6.0

func FetchRepo(dir string) (*Repo, error)

func GetRepo

func GetRepo(dir string) (*Repo, error)

Jump to

Keyboard shortcuts

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