cli icon indicating copy to clipboard operation
cli copied to clipboard

feat: new action waiting progress

Open jooola opened this issue 1 year ago • 1 comments

This replaces the 2 previous actions progress display with a single consistent one, that leverage the new hcloud.ActionWaiter functions.

image image

The progress features have been extracted in a dedicated ui package to split the actions waiting and the progress concerns.

jooola avatar May 06 '24 15:05 jooola

Codecov Report

Attention: Patch coverage is 39.51220% with 124 lines in your changes are missing coverage. Please review.

Project coverage is 59.55%. Comparing base (2cd08b2) to head (3cfd745).

Files Patch % Lines
internal/ui/progress_terminal.go 0.00% 29 Missing :warning:
internal/state/zz_command_helper_mock.go 0.00% 8 Missing :warning:
internal/cmd/server/shutdown.go 61.11% 4 Missing and 3 partials :warning:
internal/state/actions.go 78.57% 5 Missing and 1 partial :warning:
internal/ui/progress.go 40.00% 2 Missing and 4 partials :warning:
internal/ui/progress_script.go 89.65% 2 Missing and 1 partial :warning:
internal/cmd/server/create.go 0.00% 0 Missing and 2 partials :warning:
internal/cmd/base/set_rdns.go 0.00% 1 Missing :warning:
internal/cmd/certificate/create.go 0.00% 0 Missing and 1 partial :warning:
internal/cmd/firewall/add_rule.go 0.00% 0 Missing and 1 partial :warning:
... and 60 more
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #749      +/-   ##
==========================================
- Coverage   60.27%   59.55%   -0.73%     
==========================================
  Files         180      191      +11     
  Lines        6568     6770     +202     
==========================================
+ Hits         3959     4032      +73     
- Misses       1989     2115     +126     
- Partials      620      623       +3     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar May 06 '24 15:05 codecov[bot]

Looks good! I don't know about the purple text though, maybe something subtle like dark gray would be better. I see that you created a "fake" action for hcloud server shutdown --wait, it doesn't show any message for me though in my testing.

phm07 avatar May 08 '24 14:05 phm07

image image

jooola avatar May 08 '24 15:05 jooola

image

jooola avatar May 08 '24 15:05 jooola