What does the number in the p4 -I sync -q ... output mean?p4 cli
Posted 31 July 2020 - 09:47 PM
... 275 \
What is this number? I thought at first it was a percentage which would be nice, now I"m not sure. Is it the number of files it's syncing?
Whatever it is; some user feedback: I'd love if this was a bit more helpful to determine when a sync will be done.
( Ideally something like printf("%d/%d (%3.2f)", num_files_synced_so_far, num_files_to_sync_total, (num_files_synced_so_far/num_files_to_sync_total)*100.0f); )
Posted 01 August 2020 - 06:10 PM
C:\Perforce\test>p4 sync #none | wc -l 3 C:\Perforce\test>p4 -I sync -q ... ... 3 finishing
It goes by too fast in my test case to actually see progress, but I assume with more data you see that number increase from 0 to whatever the full count is. I think the idea is that if you want to gauge progress as a percentage, you'd preview the sync first with "-n" to get the total (that's what the UI does IIRC).
Posted 04 August 2020 - 07:05 PM
Posted Yesterday, 06:31 AM
If you want feedback implemented in the official build I think you have to submit that through firstname.lastname@example.org.
For features in the command line client it's actually pretty easy to just roll them yourself as long as you're okay with doing your own builds. The approach I'd suggest taking would be to implement your CLI sync progress bar as a client-side command (similar to "p4 set" or "p4 tickets") that invokes the appropriate server commands and formats the data the way you want it. A good example of this sort of extension is "px" which is a custom version of p4 that adds extra options and commands: https://swarm.worksh...shawn_hladky/px The "p4 undo" command was available in px as "p4 rollback" almost ten years before it was implemented in the server!
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users