Skip to content

feat(cmd): Run image operations with progress#330

Draft
craciunoiuc wants to merge 3 commits into
stagingfrom
craciunoiuc/add-pull-push-tracker
Draft

feat(cmd): Run image operations with progress#330
craciunoiuc wants to merge 3 commits into
stagingfrom
craciunoiuc/add-pull-push-tracker

Conversation

@craciunoiuc
Copy link
Copy Markdown
Member

@craciunoiuc craciunoiuc commented May 19, 2026

Adds a simple colored progress bar for tracking pushes/pulls.

Closes: TOOL-636
Depends on: unikraft-cloud/x#165
Needs rebase after that is merged.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds Bubble Tea–based progress UI for image load/save operations, similar to the existing download progress bar, so pushes/pulls can show a colored progress indicator when running in a terminal.

Changes:

  • Introduces RunWithImageProgress and an imgprogress tracker that aggregates per-descriptor progress into a single progress bar.
  • Improves terminal detection for progress output by unwrapping colorprofile.Writer to the underlying TTY writer.
  • Wraps image load/save paths in build and image copy commands with the new progress runner.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
internal/tui/progdl/tracker.go New image-progress runner and tracker that feeds progress updates to Bubble Tea.
internal/tui/progdl/model.go Adjusts key handling for the progress UI.
internal/tui/progdl/download.go Enhances TTY detection/unwrapping for Bubble Tea output.
internal/cmd/images.go Wraps image copy load/save with image progress UI.
internal/cmd/build.go Wraps build image save with image progress UI.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread internal/tui/progdl/tracker.go
Comment thread internal/tui/progdl/download.go Outdated
Implements the 'Update' function and exposes function
to run a writer with a progress bar. Uses 'x/image-spec'.

Signed-off-by: Cezar Craciunoiu <cezar@unikraft.io>
Signed-off-by: Cezar Craciunoiu <cezar@unikraft.io>
Adapts both 'build' and 'image inspect' to have progress
bars for tracking the status of OCI pushes/pulls.

Signed-off-by: Cezar Craciunoiu <cezar@unikraft.io>
@craciunoiuc craciunoiuc force-pushed the craciunoiuc/add-pull-push-tracker branch from 814c16f to 0ad4f56 Compare May 20, 2026 09:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants