fetchmodel

package
v1.4.0 Latest Latest
Warning

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

Go to latest
Published: May 12, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package fetchmodel provides the spinner animation that runs during the pull command at startup.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FetchModel

type FetchModel struct {
	Config    *viper.Viper
	Spinner   spinner.Model
	CmdOutput string
	Err       error
	Width     int
	Height    int
}

FetchModel defines the model used for displaying a spinner while syncing with a remote Git repository.

func NewFetchModel added in v0.21.8

func NewFetchModel(v *viper.Viper) FetchModel

NewFetchModel initializes and returns a new FetchModel instance,

func (FetchModel) Init

func (m FetchModel) Init() tea.Cmd

Init initializes the spinner model and starts the init command.

func (FetchModel) Update

func (m FetchModel) Update(msg tea.Msg) (tea.Model, tea.Cmd)

Update handles messages received during the spinner's lifecycle, such as window resize, spinner ticks, Git pull results, and user input.

func (FetchModel) View

func (m FetchModel) View() tea.View

View renders the spinner UI, displaying a loading animation or an error message, centered in the terminal window.

Jump to

Keyboard shortcuts

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