Date: Mon, 26 May 2008 15:26:59 +0200 From: "Mathieu Prevot" <mathieu.prevot@gmail.com> To: hackers@freebsd.org Subject: flush file descriptor in a sh script while passing through a pipe Message-ID: <3e473cc60805260626k2469143ay9b0d52ea4044938b@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
Hi, Let's be an example. With 1) I have a progress bar that is updated regularly but with 2) I have to wait for the end of the download (the next \n character ?) ... 1) wget http://tinyurl.com/5ztnb2 2) wget http://tinyurl.com/5ztnb2 --progress=bar:force 2>&1 | sed '/^Location/d;/^HTTP/d;/^--/d' I would like the progress bar to be updated through sed ... how can I flush the file descriptor from sh or with a tiny command/signal ? Thanks Mathieu
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3e473cc60805260626k2469143ay9b0d52ea4044938b>