ui

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2026 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RenderSourceList

func RenderSourceList(sources []SourceStatus, opts ListOptions) error

Types

type ListOptions

type ListOptions struct {
	JSON    bool
	Verbose bool
	Files   bool
}

type SourceStatus

type SourceStatus struct {
	Name      string    `json:"name"`
	Type      string    `json:"type"`
	Repo      string    `json:"repo,omitempty"`
	Path      string    `json:"path,omitempty"`
	URL       string    `json:"url,omitempty"`
	Ref       string    `json:"ref,omitempty"`
	Patterns  []string  `json:"patterns,omitempty"`
	OutputDir string    `json:"output_dir"`
	Status    string    `json:"status"`
	FileCount int       `json:"file_count,omitempty"`
	SyncedAt  time.Time `json:"synced_at,omitzero"`
}

type SyncPrinter

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

SyncPrinter renders sync progress events to stderr with colored output.

func NewSyncPrinter

func NewSyncPrinter(dryRun bool) *SyncPrinter

NewSyncPrinter creates a SyncPrinter that writes to stderr.

func NewSyncPrinterWithWriter

func NewSyncPrinterWithWriter(w io.Writer, dryRun bool) *SyncPrinter

NewSyncPrinterWithWriter creates a SyncPrinter that writes to the given writer.

func (*SyncPrinter) HandleEvent

func (p *SyncPrinter) HandleEvent(e doxsync.Event)

HandleEvent is the callback wired into sync.Options.OnEvent.

func (*SyncPrinter) PrintSummary

func (p *SyncPrinter) PrintSummary(r *doxsync.RunResult)

PrintSummary renders a final summary line after sync completes.

Jump to

Keyboard shortcuts

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