cli icon indicating copy to clipboard operation
cli copied to clipboard

feat: added the progress bar for generate command.

Open ItshMoh opened this issue 1 year ago • 7 comments

Description Added a progress bar for the generate command in the cli.

https://www.loom.com/share/72534057ea2644f997bae71fb4c79957?sid=7e05ac94-c362-4860-9dfb-333ff07bfff4

Related issue(s) fixes #1410

ItshMoh avatar Oct 20 '24 21:10 ItshMoh

Thanks for the PR @ItshMoh Please include this in all the commands of the CLI and fix Quality Gate

AayushSaini101 avatar Oct 21 '24 04:10 AayushSaini101

Thanks for the PR @ItshMoh Please include this in all the commands of the CLI and fix Quality Gate

Sure @AayushSaini101

ItshMoh avatar Oct 21 '24 06:10 ItshMoh

@ItshMoh how is the progress being calculated ?

Shurtu-gal avatar Oct 21 '24 06:10 Shurtu-gal

Quality Gate Failed Quality Gate failed

Failed conditions
29.3% Duplication on New Code (required ≤ 3%)

See analysis details on SonarCloud

sonarqubecloud[bot] avatar Oct 21 '24 12:10 sonarqubecloud[bot]

@ItshMoh how is the progress being calculated ?

Hey @Shurtu-gal I have updated the logic. So in the new logic here i have divided it into 3 steps. The first step is Initializing generator , Generating Files and the last for completion of generation. After the step the progress bar increases. Do you have anything extra that i can add?

ItshMoh avatar Oct 21 '24 14:10 ItshMoh

Hey @Shurtu-gal I have updated the logic. So in the new logic here i have divided it into 3 steps. The first step is Initializing generator , Generating Files and the last for completion of generation. After the step the progress bar increases. Do you have anything extra that i can add?

What I am not understanding is how is a progress bar different from the current spinner we have if we don't have any way to measure the current progress in generation.

Note: @Souvikns has also proposed removing the spinner altogether https://github.com/amplication

Shurtu-gal avatar Oct 22 '24 11:10 Shurtu-gal

What I am not understanding is how is a progress bar different from the current spinner we have if we don't have any way to measure the current progress in generation.

Note: @Souvikns has also proposed removing the spinner altogether https://github.com/amplication

Hey @Shurtu-gal Should i remove the spinner alltogether ?

ItshMoh avatar Oct 22 '24 13:10 ItshMoh

@Souvikns do require this feature to be there as we don't have any set time or some kind of progress parameter I guess this would rather just be a aesthetic thing.

Shurtu-gal avatar Dec 09 '24 05:12 Shurtu-gal

Yeah what we have right now work, but having a progress bar is causing some problems with new generator as well. So we have to consider that as well. @ItshMoh do consider this https://github.com/asyncapi/cli/issues/1540 as well, if you can add a progress bar and not create the same problem with the new generator that there is no issue.

Souvikns avatar Dec 30 '24 14:12 Souvikns

Any updates @ItshMoh?

Shurtu-gal avatar Mar 17 '25 20:03 Shurtu-gal

Hey @Shurtu-gal I am not able to work on it currently. So closing the PR.

ItshMoh avatar Mar 18 '25 06:03 ItshMoh