Help us shape the future of Go! Take the 2026 Go Developer Survey

git

package
v0.0.0-...-09a8bdb Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2026 License: MIT Imports: 14 Imported by: 0

Documentation

Overview

Package git shows the state of a set of local repositories: what branch each is on, how far it has drifted from its upstream, what is uncommitted, and how long ago anyone touched it.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(ctx widget.Context) (widget.Widget, error)

New builds a git widget from its dashboard configuration.

Types

type Git

type Git struct {
	widget.Base
	// contains filtered or unexported fields
}

Git lists repositories and their state.

func (*Git) Actions

func (g *Git) Actions() []widget.Action

Actions names what enter does, which depends on the level: opening a repository from the list, or staging the file under the cursor inside one.

func (*Git) GrabsKeys

func (g *Git) GrabsKeys() bool

GrabsKeys claims the keyboard while a commit message is being typed.

func (*Git) Init

func (g *Git) Init() tea.Cmd

Init kicks off the first scan and starts the refresh tick.

func (*Git) Lines

func (g *Git) Lines(int) int

Lines is the widget.Liner contract: how tall this widget's content wants to be.

A widget offered a single line takes it and renders the strip — which is how the status bar gets a one-line summary without the dashboard having to say so. Anywhere taller, a list wants a line per repository.

func (*Git) Update

func (g *Git) Update(msg tea.Msg) tea.Cmd

Update handles navigation, local keys and scan results.

func (*Git) View

func (g *Git) View() string

View renders the repository list.

Jump to

Keyboard shortcuts

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