Xfennec / progress

Linux tool to show progress for cp, mv, dd, ... (formerly known as cv)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Monitor progress of piped commands

CircleCode opened this issue · comments

it seems progress is not able to get the progression of a piped command

for example:

❯ progress -c xz
[ 7525] xz …/signal-desktop-bin/signal-desktop-bin-1.23.1-1-x86_64.pkg.tar.xz
	100.0% (53.1 MiB / 53.1 MiB)

❯ progress -wc xz
[ 7525] xz …/signal-desktop-bin/signal-desktop-bin-1.23.1-1-x86_64.pkg.tar.xz
	100.0% (70.2 MiB / 70.2 MiB) 295.9 KiB/s

❯ ps -o args 7525
COMMAND
xz -c -z -

I wasn't able to find what was piped to xz because the process terminated before I had time to investigate, but I was running arch update through yay.
From a top output, I suppose this was piped from a bsdtar command, but I do not have its details.

Should progress be able to monitor process receiving their input from piped command (I suppose it should be possible to follow the pipe, but I don't know at all how complex this could be)