git

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2026 License: MIT Imports: 15 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

Overview

Package git wraps the git CLI for gitree.

Index

Constants

View Source
const NetworkTimeout = 60 * time.Second

NetworkTimeout bounds one pull or push (and its ssh / remote helpers).

Variables

View Source
var (
	// ErrDetached is returned when pull or push is asked for without a branch.
	ErrDetached = errors.New("HEAD is detached: check out a branch first")
	// ErrDiverged means the branch and its upstream both have commits: a
	// fast-forward pull is impossible and nothing was changed.
	ErrDiverged = errors.New("branches diverged: pull with lazygit (L)")
	// ErrRejected is a push the remote refused because it has new commits.
	ErrRejected = errors.New("push rejected: remote has new commits — pull first (p)")
	// ErrNothingToPush is returned, without running git, when the branch has
	// no commits its upstream lacks.
	ErrNothingToPush = errors.New("nothing to push")
	// ErrNoUpstream is returned by Pull for a branch that tracks nothing.
	ErrNoUpstream = errors.New("no upstream: push first with P")
	// ErrBranchChanged is returned by Push when the branch or its push
	// destination is no longer the one that was confirmed.
	ErrBranchChanged = errors.New("branch changed — try again")
)
View Source
var DeltaArgs = []string{
	"--dark", "--paging=never", "--line-numbers", "--syntax-theme=gruvbox-dark",
	`--plus-style=syntax "#34381b"`, `--plus-emph-style=syntax "#4b5a26"`,
	`--minus-style=syntax "#402120"`, `--minus-emph-style=syntax "#6a2e2b"`,
	"--line-numbers-plus-style=#a9b665", "--line-numbers-minus-style=#ea6962",
	"--line-numbers-zero-style=#7c6f64",
	"--hunk-header-style=file line-number syntax", "--hunk-header-decoration-style=#665c54 box",
	"--file-style=#d8a657 bold", "--file-decoration-style=#665c54 ul",
}

DeltaArgs are the delta flags (from the lazygit config), one argv element each.

View Source
var ErrControlName = errors.New("branch name contains control characters: use git directly")

ErrControlName is returned when an action would involve a branch whose real name contains control characters. Names are sanitized for display, so the name shown could be another branch's; gitree refuses instead of guessing.

View Source
var ErrDirty = errors.New("there are uncommitted changes in tracked files")

ErrDirty is returned, without running git, when tracked files have uncommitted changes. gitree never stashes automatically.

View Source
var ErrInProgress = errors.New("a merge, cherry-pick, revert or rebase is in progress")

ErrInProgress is returned, without running git, when a merge, cherry-pick, revert or rebase is in progress: it has to be finished (in lazygit) first.

View Source
var ErrNotMerged = errors.New("branch is not fully merged")

ErrNotMerged is returned by DeleteBranch when a safe delete (-d) is refused because the branch has commits that are not merged.

View Source
var ErrNotRepo = errors.New("not a git repository")

ErrNotRepo is returned by Open when the path is not inside a git repository.

View Source
var LookPath = exec.LookPath

LookPath locates executables; overridable in tests.

Functions

func GoneError

func GoneError(upstream string) error

GoneError reports an upstream branch that no longer exists.

func SanitizeLine

func SanitizeLine(s string) string

SanitizeLine removes control characters and terminal escape sequences from text that came from the repository (subjects, names, ref names), so it can never reach the terminal raw. Tabs become spaces; everything else that is a control character (C0, DEL, C1) is dropped, along with the rest of any ESC / CSI / OSC sequence it starts.

Types

type ActionError

type ActionError struct {
	Op               string
	Output           string
	Conflict         bool
	InProgress       bool
	Blocked          []string
	BlockedUntracked bool
}

ActionError is a failed repo-mutating git command. When Conflict is true the repo is deliberately left in the conflicted state for the user to resolve. InProgress means the failed merge/cherry-pick left an operation in progress (always with Conflict; alone e.g. for an empty cherry-pick). It is never aborted automatically.

Blocked lists the files git refused to overwrite (nothing was changed): untracked files when BlockedUntracked, otherwise local changes.

func (*ActionError) Error

func (e *ActionError) Error() string

type AutostashConflictError

type AutostashConflictError struct{ Commits int }

AutostashConflictError is returned by PullAutostash when the pull (Commits commits) was applied but the stashed local changes conflicted when git restored them: git keeps them in the stash and leaves the conflicts in the working tree for the user to resolve.

func (*AutostashConflictError) Error

func (e *AutostashConflictError) Error() string

type AutostashKeptError

type AutostashKeptError struct{ Cause error }

AutostashKeptError is returned by PullAutostash when the pull did not finish (Cause: timed out, killed, …) after git had stashed the local changes: gitree moved them into the stash (`git merge --quit`), where they wait to be restored.

func (*AutostashKeptError) Error

func (e *AutostashKeptError) Error() string

func (*AutostashKeptError) Unwrap

func (e *AutostashKeptError) Unwrap() error

type CheckoutKind

type CheckoutKind int

CheckoutKind is what a CheckoutTarget names.

const (
	// CheckoutLocal switches to the local branch Name.
	CheckoutLocal CheckoutKind = iota
	// CheckoutTrack creates a local branch tracking the remote branch Name
	// ("origin/x") and switches to it.
	CheckoutTrack
	// CheckoutDetached checks out commit Name (a hash) with a detached HEAD.
	CheckoutDetached
)

type CheckoutRestoredError

type CheckoutRestoredError struct {
	Err  error
	Kept bool
}

CheckoutRestoredError is a checkout that failed after gitree stashed the local changes: HEAD did not move and they were restored on the original branch. Err is git's refusal (often an *ActionError). Kept means the stash entry could not be dropped safely and is still in the stash.

func (*CheckoutRestoredError) Error

func (e *CheckoutRestoredError) Error() string

func (*CheckoutRestoredError) Unwrap

func (e *CheckoutRestoredError) Unwrap() error

type CheckoutResult

type CheckoutResult struct {
	Unstaged bool
	Hook     string
	Kept     bool
}

CheckoutResult is a successful CheckoutWithStash: Unstaged when the staged state could not be restored (the changes came back unstaged), Hook the failed post-checkout hook's first error line, Kept when the stash entry was restored but left in the stash (the stash changed meanwhile).

type CheckoutTarget

type CheckoutTarget struct {
	Kind CheckoutKind
	Name string
}

CheckoutTarget is what a checkout switches to.

type CmdError

type CmdError struct {
	Args     []string
	Stdout   string // what git printed before failing (e.g. "CONFLICT (content): …")
	Stderr   string
	ExitCode int
}

CmdError describes a failed git invocation.

func (*CmdError) Error

func (e *CmdError) Error() string

type Commit

type Commit struct {
	Hash        string
	Parents     []string
	Refs        []Ref
	AuthorName  string
	AuthorEmail string
	Time        time.Time
	Subject     string
}

Commit is one entry of the log.

type CommitMeta

type CommitMeta struct {
	Hash                          string
	AuthorName, AuthorEmail       string
	AuthorDate                    time.Time
	CommitterName, CommitterEmail string
	Subject                       string
	Body                          string   // the full raw message (unsanitized: never print it as is)
	CoAuthors                     []string // names from Co-authored-by trailers
}

CommitMeta is the metadata the preview header shows for a commit.

func (CommitMeta) CommitterDiffers

func (c CommitMeta) CommitterDiffers() bool

CommitterDiffers reports whether someone other than the author committed.

type DiffTarget

type DiffTarget struct{ Hash, OldPath string }

DiffTarget selects what to diff. Hash == "" means working tree vs HEAD. OldPath is the pre-rename path of the file being diffed (optional); with it both paths are passed so git can pair them and show a rename, not an add.

type FileChange

type FileChange struct {
	Status  byte
	Path    string
	Staged  bool // some of the change is in the index (TrackedChanges only)
	OldPath string
	Added   int
	Deleted int
}

FileChange is one changed file. Status is one of 'M','A','D','R','?'.

type GoneUpstreamError

type GoneUpstreamError struct{ Upstream string }

GoneUpstreamError reports an upstream branch that no longer exists.

func (*GoneUpstreamError) Error

func (e *GoneUpstreamError) Error() string

type HookFailedError

type HookFailedError struct{ Line string }

HookFailedError is a checkout that happened (HEAD moved) but whose post-checkout hook failed; Line is the hook's first error line.

func (*HookFailedError) Error

func (e *HookFailedError) Error() string

type Host added in v0.6.0

type Host int

Host is a web forge gitree knows how to link to.

const (
	HostGitHub Host = iota
	HostGitLab
	HostBitbucket
)

type PushKind

type PushKind int

PushKind says where a push goes relative to the branch's upstream.

const (
	// PushUpstream pushes to the existing, same-named upstream branch.
	PushUpstream PushKind = iota
	// PushNewBranch pushes to a same-named branch on origin and makes it the
	// upstream: used without an upstream, or when the upstream is a local
	// branch or has a different name (pushing there would publish the
	// commits onto another branch, which push.default=simple refuses too).
	PushNewBranch
	// PushRecreate pushes to the upstream branch, which was deleted on the
	// remote, recreating it.
	PushRecreate
)

type PushPlan

type PushPlan struct {
	Branch string
	Remote string
	Target string
	Kind   PushKind
	Ahead  int
}

PushPlan is what a push will do: Branch (local) goes to Target on Remote. Ahead is the number of commits to push for PushUpstream.

func PlanPush

func PlanPush(branch string, t Track, ok bool) (PushPlan, error)

PlanPush decides how branch is pushed given its upstream info (ok false: none). It fails with ErrDetached for "" and ErrNothingToPush when the upstream already has every commit.

func (PushPlan) Dest

func (p PushPlan) Dest() string

Dest is the remote-tracking name of the destination ("origin/feature").

type Ref

type Ref struct {
	Name   string
	Kind   RefKind
	IsHead bool
	Remote string
}

Ref is a branch, tag or HEAD pointing at a commit. Name is "develop", "origin/develop", "v1.0" or "HEAD". Remote is the remote of a RemoteBranch ("origin"), "" otherwise.

func ParseDecorations

func ParseDecorations(d string, remotes []string) []Ref

ParseDecorations parses git's %D output. A name is a remote branch when it is prefixed by "<remote>/" for one of remotes; remote HEAD symrefs are dropped. Control characters are stripped from the names.

type RefInfo

type RefInfo struct {
	Name   string
	Kind   RefKind
	Remote string
	Hash   string
}

RefInfo is one branch or tag of the repo for the branch picker. Name is short ("develop", "origin/develop", "v1.0"); Remote is the remote of a RemoteBranch ("origin"), "" otherwise; Hash is the commit it points at (annotated tags are peeled).

type RefKind

type RefKind int

RefKind classifies a decoration on a commit.

const (
	LocalBranch RefKind = iota
	RemoteBranch
	Tag
	DetachedHead
)

type Repo

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

Repo is an opened git repository.

func Open

func Open(path string) (*Repo, error)

Open resolves the repository containing path.

func (*Repo) BranchExists

func (r *Repo) BranchExists(name string) bool

BranchExists reports whether the local branch name exists.

func (*Repo) Checkout

func (r *Repo) Checkout(t CheckoutTarget) error

Checkout switches to t, refusing with ErrInProgress or ErrDirty first. A checkout that moved HEAD but whose post-checkout hook failed is a *HookFailedError (the checkout happened).

func (*Repo) CheckoutBranch

func (r *Repo) CheckoutBranch(name string) error

CheckoutBranch switches to a local branch.

func (*Repo) CheckoutDetached

func (r *Repo) CheckoutDetached(hash string) error

CheckoutDetached checks out a commit in detached HEAD state.

func (*Repo) CheckoutRemote

func (r *Repo) CheckoutRemote(remoteBranch string) error

CheckoutRemote creates a local branch tracking remoteBranch ("origin/x") and switches to it.

func (*Repo) CheckoutWithStash

func (r *Repo) CheckoutWithStash(t CheckoutTarget) (CheckoutResult, error)

CheckoutWithStash checks out t with uncommitted changes in tracked files: it stashes them (`git stash push`, untracked files stay where they are), checks out t and restores them (`git stash apply --index`, then drops the entry while it is still stash@{0}). It is only run after the user explicitly confirmed it.

When the checkout fails without moving HEAD the changes are restored on the original branch and the error is a *CheckoutRestoredError. When HEAD moved (a failing post-checkout hook) the changes are restored on the new branch and the hook is reported. When restoring conflicts it is a *StashConflictError (the entry is kept). When the staged state cannot be restored the changes come back unstaged. A stash entry is never dropped on a failure path.

func (*Repo) CherryPick

func (r *Repo) CherryPick(hash string) error

CherryPick applies commit hash onto the current branch.

func (*Repo) CommitFiles

func (r *Repo) CommitFiles(hash string) ([]FileChange, error)

CommitFiles lists files changed by a commit versus its first parent (or the empty tree for a root commit).

func (*Repo) CommitMeta

func (r *Repo) CommitMeta(hash string) (CommitMeta, error)

CommitMeta reads the author, committer, date and message of a commit with a single git call.

func (*Repo) CreateBranch

func (r *Repo) CreateBranch(name, at string) error

CreateBranch creates branch name at the given commit/ref without switching.

func (*Repo) CreateTag added in v0.6.0

func (r *Repo) CreateTag(name, at, message string) error

CreateTag tags the commit/ref at: lightweight when message is empty, annotated otherwise.

func (*Repo) CurrentBranch

func (r *Repo) CurrentBranch() (string, error)

CurrentBranch returns the checked-out branch name, or "" when detached.

func (*Repo) CurrentBranchRaw

func (r *Repo) CurrentBranchRaw() (string, error)

CurrentBranchRaw returns the checked-out branch name exactly as git reports it, "" when detached. Use it for comparisons and git arguments, never for display.

func (*Repo) DeleteBranch added in v0.6.0

func (r *Repo) DeleteBranch(name string, force bool) error

DeleteBranch deletes the local branch name. Without force, a branch with unmerged commits is refused with ErrNotMerged.

func (*Repo) DeleteRemoteBranch added in v0.6.0

func (r *Repo) DeleteRemoteBranch(ctx context.Context, remote, branch string) error

DeleteRemoteBranch deletes branch on remote (`git push --delete`).

func (*Repo) Diff

func (r *Repo) Diff(t DiffTarget, path string, width int) (string, error)

Diff returns the colored diff for a commit or the working tree, piped through delta when available. path "" means the whole commit/working tree.

func (*Repo) Fetch

func (r *Repo) Fetch(ctx context.Context) error

Fetch updates all remotes and prunes deleted branches. It never prompts: git gets GIT_TERMINAL_PROMPT=0 (runCtx), credential helpers are told not to be interactive, and runCtx detaches git from the controlling terminal so ssh cannot ask for a passphrase either. The user's own ssh configuration (core.sshCommand, GIT_SSH_COMMAND, ...) is left untouched. ctx bounds the whole operation, children included.

func (*Repo) Fingerprint added in v0.2.0

func (r *Repo) Fingerprint() (string, error)

Fingerprint summarizes HEAD and every ref (branches, remote branches, tags, the stash) with their commits. Two equal fingerprints mean the log, labels and current branch would load the same, so polling it is a cheap way to notice changes made outside gitree. The index and working tree are not part of it (git status refreshes the index on its own).

func (*Repo) GitreeStashes

func (r *Repo) GitreeStashes() ([]StashEntry, error)

GitreeStashes lists the stash entries gitree made for a checkout (their message starts with "gitree: checkout "), wherever they are in the stash.

func (*Repo) HasTrackedChanges

func (r *Repo) HasTrackedChanges() (bool, error)

HasTrackedChanges reports whether any tracked file differs from HEAD.

func (*Repo) HeadHash

func (r *Repo) HeadHash() (string, error)

HeadHash returns the full hash HEAD points at.

func (*Repo) InHistory added in v0.7.0

func (r *Repo) InHistory(hash string) (bool, error)

InHistory reports whether commit hash is reachable from HEAD.

func (*Repo) InProgress

func (r *Repo) InProgress() (bool, error)

InProgress reports whether a merge, cherry-pick, revert or rebase is in progress.

func (*Repo) ListRefs

func (r *Repo) ListRefs() ([]RefInfo, error)

ListRefs returns the local branches, remote branches (without the <remote>/HEAD symrefs) and tags, ordered local → remote → tag and alphabetically (ignoring case) within each group. Tags that do not lead to a commit (a tree or blob) are left out; a tag of a tag is peeled to its commit with rev-parse.

func (*Repo) LocalBranchFor

func (r *Repo) LocalBranchFor(remoteBranch string) (name string, exists bool, err error)

LocalBranchFor finds the local copy of remoteBranch ("origin/x"): the local branch whose upstream it is, else a local branch with the name after the remote. exists is false when there is none; name is then the branch `git checkout --track` would create.

func (*Repo) Log

func (r *Repo) Log(scope Scope, skip, limit int) ([]Commit, error)

Log returns commits for scope in topological order, newest first.

func (*Repo) Merge

func (r *Repo) Merge(branch string) error

Merge merges branch into the current branch (fast-forward when possible).

func (*Repo) Message

func (r *Repo) Message(hash string) (string, error)

Message returns the full commit message of hash (subject and body).

func (*Repo) Pull

func (r *Repo) Pull(ctx context.Context) (int, error)

Pull fast-forwards the current branch to its upstream (`git pull --ff-only`) and returns how many commits it brought (0: already up to date). It never merges, rebases or stashes: uncommitted changes in tracked files are ErrDirty.

func (*Repo) PullAutostash

func (r *Repo) PullAutostash(ctx context.Context) (int, error)

PullAutostash is Pull for a dirty tree: git stashes the tracked changes, fast-forwards and restores them (`--autostash`). It is only run after the user explicitly confirmed it. When restoring conflicts the pull stays applied and the error is an *AutostashConflictError.

func (*Repo) Push

func (r *Repo) Push(ctx context.Context, want PushPlan) error

Push pushes the current branch as want (a plan the user confirmed). The plan is made again first: if the branch or its destination changed meanwhile it fails with ErrBranchChanged and pushes nothing. Branches always go to a same-named remote branch, with explicit refspecs. It never forces: a rejected push is ErrRejected.

func (*Repo) PushPlan

func (r *Repo) PushPlan() (PushPlan, error)

PushPlan plans a push of the current branch from the repo's state now.

func (*Repo) RenameBranch added in v0.6.0

func (r *Repo) RenameBranch(old, new string) error

RenameBranch renames the local branch old to new. It never overwrites an existing branch.

func (*Repo) Reset added in v0.7.0

func (r *Repo) Reset(mode ResetMode, hash string) error

Reset moves the current branch to hash. Uncommitted changes are allowed (hard discards them; ResetImpact says which).

func (*Repo) ResetImpact added in v0.7.0

func (r *Repo) ResetImpact(hash string) (ResetImpact, error)

ResetImpact reports the facts a reset confirmation needs.

func (*Repo) Revert added in v0.7.0

func (r *Repo) Revert(hash string, merge bool) error

Revert creates a commit undoing hash on the current branch. merge selects the first parent as mainline, for reverting a merge commit.

func (*Repo) Root

func (r *Repo) Root() string

Root returns the repository top-level directory.

func (*Repo) SetUpstream added in v0.6.0

func (r *Repo) SetUpstream(branch, upstream string) error

SetUpstream makes branch track upstream ("origin/x"), which must be an existing remote-tracking branch.

func (*Repo) ShowHeader

func (r *Repo) ShowHeader(hash string) (string, error)

ShowHeader returns the full hash, author, date and full message of a commit.

func (*Repo) SplitRemoteRef added in v0.6.0

func (r *Repo) SplitRemoteRef(name string) (remote, branch string, ok bool)

SplitRemoteRef splits a remote-tracking name ("origin/feature/x") into its remote and branch; the longest matching remote name wins.

func (*Repo) Stats added in v0.5.0

func (r *Repo) Stats(hashes []string) (map[string]Stat, error)

Stats returns the line totals of each commit in hashes, from a single git call. Every commit git reports gets an entry; merges (no diff by default), empty commits and binary-only changes are the zero Stat.

func (*Repo) TagExists added in v0.6.0

func (r *Repo) TagExists(name string) bool

TagExists reports whether the tag name exists.

func (*Repo) TrackedChanges

func (r *Repo) TrackedChanges() ([]FileChange, error)

TrackedChanges lists the tracked files that differ from HEAD (staged or not), without line counts: what ErrDirty is about.

func (*Repo) Tracking

func (r *Repo) Tracking() (map[string]Track, error)

Tracking returns upstream info keyed by local branch name. Branches without an upstream are omitted.

func (*Repo) ValidBranchName

func (r *Repo) ValidBranchName(name string) bool

ValidBranchName reports whether name is acceptable as a branch name (git check-ref-format --branch). Names starting with '-' are rejected.

func (*Repo) ValidTagName added in v0.6.0

func (r *Repo) ValidTagName(name string) bool

ValidTagName reports whether name is acceptable as a tag name.

func (*Repo) Web added in v0.6.0

func (r *Repo) Web(remote string) (WebRemote, bool)

Web is the web address of remote, from its configured URL as written (not `remote get-url`, which applies insteadOf rewrites).

func (*Repo) WorkingFiles

func (r *Repo) WorkingFiles() ([]FileChange, error)

WorkingFiles lists tracked changes (staged+unstaged vs HEAD) plus untracked files as '?'.

type ResetImpact added in v0.7.0

type ResetImpact struct {
	Leaving    int      // commits that would leave the branch
	OnUpstream int      // of those, commits already on Upstream
	Upstream   string   // short upstream name; "" when none, gone or local
	Lost       []string // paths a hard reset discards or overwrites
}

ResetImpact is what resetting the current branch to a commit would affect.

type ResetMode added in v0.7.0

type ResetMode string

ResetMode is how far `git reset` rewinds: the branch only (soft), the index too (mixed) or the working tree as well (hard).

const (
	ResetSoft  ResetMode = "soft"
	ResetMixed ResetMode = "mixed"
	ResetHard  ResetMode = "hard"
)

type Scope

type Scope int

Scope selects which refs the log walks.

const (
	// ScopeDefault walks local branches, their upstreams and HEAD.
	ScopeDefault Scope = iota
	// ScopeAll walks all branches, remotes, tags and HEAD (not stash).
	ScopeAll
)

type StashConflictError

type StashConflictError struct {
	Target string
	Entry  string
	Hash   string
	Hook   string
}

StashConflictError means the checkout of Target succeeded but the stashed changes conflicted when restored: the entry (Entry, commit Hash) stays in the stash and the conflicts are left in the working tree. Hook is set when the post-checkout hook failed too.

func (*StashConflictError) Error

func (e *StashConflictError) Error() string

type StashEntry

type StashEntry struct {
	Ref     string
	Hash    string
	Message string
}

StashEntry is one stash entry: Ref ("stash@{1}"), its commit and message.

type StashKeptError

type StashKeptError struct {
	Cause error
	Entry string
	Hash  string
}

StashKeptError means the stashed changes could not be restored (Cause): they are still in the stash entry Entry (commit Hash), untouched.

func (*StashKeptError) Error

func (e *StashKeptError) Error() string

func (*StashKeptError) Unwrap

func (e *StashKeptError) Unwrap() error

type Stat added in v0.5.0

type Stat struct {
	Added, Deleted int
}

Stat is the number of lines a commit adds and deletes, over all files.

type Track

type Track struct {
	Upstream       string
	Remote         string
	UpstreamBranch string
	Ahead          int
	Behind         int
	Gone           bool
}

Track describes how a local branch relates to its upstream. Upstream is the short name ("origin/feature/x"); Remote is the upstream's remote ("origin", or "." for a local branch); UpstreamBranch is the branch name on that remote ("feature/x"). Gone means the upstream branch no longer exists (deleted on the remote and pruned).

type WebRemote added in v0.6.0

type WebRemote struct {
	Host Host
	Base string
}

WebRemote is a remote's repository page: Base is https://<host>/<owner>/<repo>, without ".git".

func ParseWebRemote added in v0.6.0

func ParseWebRemote(remoteURL string) (WebRemote, bool)

ParseWebRemote turns a remote URL (https://, ssh://git@ or git@host:path) of a known forge into its web address; ok is false for anything else.

func (WebRemote) CommitURL added in v0.6.0

func (w WebRemote) CommitURL(hash string) string

CommitURL is the web page of the commit with the given hash.

func (WebRemote) CompareURL added in v0.6.0

func (w WebRemote) CompareURL(branch string) string

CompareURL is GitHub's "open a pull request" page for branch.

Jump to

Keyboard shortcuts

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