#93 Add little verbosity to all flags

Closed on November 28, 2020
arijid79 on November 17, 2020

Flags such as push, pull, clone should have a output as they are running. This gives information on what the program is going for. It should have outputs like, for the push command

Connecting to nest.pijul.com...
Sending <WHATEVER NUMBER OF PATCHES>....
Done

Or something like that

If a user runs a pijul pull <some URL> when he/she is up to date with it. Some output should come like

Connecting to nest.pijul.com...
Everything is up to date

Also, for the clone subcommand, I recommend telling what steps did the program took instead of saying what patches it applied. Example output:-

Connecting to nest.pijul.com...
Downloading patches...
Applying patches....
Done

While doing apply orpull and a conflict occurs, there should be some output telling about those files. A pijul status subcommand would be amazing

pmeunier on November 25, 2020

My next target on this project is fixing the issues with SSH. This is a very fine suggestion, thanks.

pmeunier added a change on November 27, 2020
Q45QHPO4HDTEZF2W4UDZSYYQ46BPEIWSW4GJILZR5HTJNLKXJABQC
main
pmeunier on November 27, 2020

Done, thanks! The “indicatif” crate is fantastic (the name is cool too).

pmeunier closed this discussion on November 27, 2020
arijid79 on November 27, 2020

Cool. Checking it out right now

pmeunier on November 27, 2020

I just noticed I forgot push. Doing this right now.

arijid79 on November 27, 2020

Yeah. It’s great but there are some weird output going on

For HTTP(S)

Downloading changes

Applying changes

   Outputting repository

For SSH

   Cloning channel
Downloading changes

Outputting repository
  • Why are there spaces in some lines.
  • Is there any specific reason to have different output for different protocols. Because I think it should have same output for whatever method one uses

I am running the clone command

Also, why the pull command only tells about downloading changes and not about applying them

arijid79 reopened this discussion on November 27, 2020
pmeunier on November 27, 2020

Why are there spaces in some lines.

There’s a little spinner spinning next to “Cloning channel”. I think it is less intuitive if “Cloning channel” moves to the left at the end. Maybe we could replace the spinner with something else once it’s done.

Is there any specific reason to have different output for different protocols

Yes. Not all protocols implement the same functions. For example, in order to implement the channel cloning feature (which is supposed to be faster than cloning and applying), HTTP 1.1 should open a websocket, which makes everything super complicated both on the server and on the client.

But SSH allows that, so we can use the faster thing.

pmeunier added a change on November 27, 2020
K6GWUOD55G377RVEEMMRPZ4EUAHCM2BGXNRJTE5UZJFFMJGFCEZQC
main
pmeunier on November 27, 2020

What do you think of the improved style?

pmeunier added a change on November 28, 2020
367UBQ6KNAKUEWG32R4QRJ6H7IE7NAZFOPTC3ZOE4Z6E44RV3ISQC
main
pmeunier added a change on November 28, 2020
PCEJFKFXAFGYGHMM4BOBGFV3WRFXEBF2UQYQHLJ7MURRYBKRM3EAC
main
pmeunier closed this discussion on November 28, 2020