Categorygithub.com/vito/progrock
modulepackage
0.10.1
Repository: https://github.com/vito/progrock.git
Documentation: pkg.go.dev

# README

progrock Go Reference

progress UI that rocks

Progrock is a toolkit for streaming, recording, and displaying concurrent progress of inter-dependent vertexes in an execution graph.

Here's how it looks (from Bass):

https://github.com/vito/bass/assets/1880/ab05445c-95f7-44b6-a67b-d9fc8eb02d41

usage

thanks

This repository originally housed code extracted directly from Buildkit, though it has since been reimplemented from scratch with only the protocol bearing any resemblance.

# Packages

No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# Functions

No description provided by the author
No description provided by the author
DialRPC dials a ProgressService at the given target.
ErrorLabel is shorthand for Labelf("error", "%s", err).
Focused marks the vertex as focused, indicating it should be shown in the UI when in focus mode.
FromContext returns the Recorder attached to the given context, or a no-op Recorder if none is attached.
Internal marks the vertex as internal, meaning it will not be included in progress output by default.
Labelf is a convenience function for creating a Label from a format string and values.
No description provided by the author
NewRecorder creates a new Recorder which writes to the given Writer.
NewRPCReceiver returns a new RPCReceiver.
NewRPCWriter returns a new RPCWriter.
NewTape returns a new Tape.
No description provided by the author
No description provided by the author
RecorderFromContext returns the Recorder attached to the given context, or a no-op Recorder if none is attached.
RecorderToContext returns a new context with the given Recorder attached.
No description provided by the author
ServeRPC serves a ProgressService over the given listener.
ToContext returns a new context with the given Recorder attached.
Weak indicates that the group should not be considered equal to non-weak groups.
WithGroup is shorthand for FromContext(ctx).WithGroup(name, opts...).
WithGroupID sets the ID for the group.
WithInputs sets the inputs for the vertex.
WithLabels sets labels on the group.
WithMessageCode sets the message code.
WithMessageLabels sets the message labels.
WithMessageLevel sets the message level.
WithStarted sets the start time of the group.
No description provided by the author
Zoomed marks the vertex as zoomed, indicating it should take up as much screen space as possible.

# Constants

STDOUT is /dev/stderr.
STDIN is /dev/stdin.
STDOUT is /dev/stdout.
DEBUG indicates that the message should only be shown if debugging is enabled.
ERROR indicates that the message should be shown to the user, and that executation of the program cannot continue.
INVALID is not a valid message level.
WARNING indicates that the message should be shown to the user at all times, but that execution of the program can continue as normal.
No description provided by the author
RootGroup is the name of the outermost group.
RootID is "_root", the static ID value set for all Root groups.

# Variables

Clock is used to determine the current time.
No description provided by the author
Enum value maps for LogStream.
Enum value maps for LogStream.
Enum value maps for MessageLevel.
Enum value maps for MessageLevel.
ProgressService_ServiceDesc is the grpc.ServiceDesc for ProgressService service.

# Structs

No description provided by the author
Group is used to group related vertexes.
Label is a name/value pair used for annotation.
Membership declares a set of vertexes to be members of a group.
Message is a message to display to the user at a global level.
No description provided by the author
Recorder is a Writer that also tracks a current group.
RPCReceiver is a ProgressServiceServer that writes to a Writer.
RPCWriter is a Writer that writes to a ProgressService.
No description provided by the author
StatusUpdate contains a snapshot of state updates for the graph.
Tape is a Writer that collects all progress output for displaying in a terminal UI.
No description provided by the author
No description provided by the author
UnimplementedProgressServiceServer must be embedded to have forward compatible implementations.
Vertex is a node in the graph of work to be done.
No description provided by the author
VertexInstance identifies a vertex at a specific point in time.
VertexLog is a log message from a vertex.
VertexRecorder records updates pertaining to a vertex.
VertexTask is a task that a vertex is performing.
WaitWriter is a Writer that waits for the RPC server to stop before closing the underlying Writer.

# Interfaces

MessageOpt is an option for creating a Message.
No description provided by the author
No description provided by the author
ProgressServiceClient is the client API for ProgressService service.
ProgressServiceServer is the server API for ProgressService service.
No description provided by the author
UIClient is an interface for miscellaneous UI-only knobs.
UnsafeProgressServiceServer may be embedded to opt out of forward compatibility for this service.
No description provided by the author

# Type aliases

GroupOpt is an option for creating a Group.
LogStream is the standard stream that a log message was emitted to.
MessageLevel indicates the severity of a message.
No description provided by the author
No description provided by the author
TermSetupFunc is a function that gets called when the vertex's zoomed pane resizes.
VertexOpt is an option for creating a Vertex.