Seeing console progress messages in Shake -


I am using Shake, Calling wget to download the file if I I see a one-line progress bar on the command line, but when called by shake I get several lines as an example:

  shake shakeups $ action ( CMD "wget ​​http://hackage.haskell.org/packages/index.tar.gz" :: Action ())  

I want to show the one-line progress bar Wanting .

is the solution:

  shake shakeopopations {shellline buffering = fail} $ Action (CMD "wget ​​http://hackage.haskell.org/packages/index.tar.gz --progress = bar: force" :: action ())  

Here are two things:

1) wget detects that it is not sending direct to the console (since the cmd of pipes Captures the output by using it), and closes the progress bar with wget , you get that code from - progress = bar: force Lu can. 2) Once I have done this, the progress bar is not actually displayed, because Shake starts the line buffering by default (this helps in executing commands in the least displayed output in the command ) And a progress bar is updated only in one line, you can fix it by setting the shakeLineBuffering = False option.


Comments

Popular posts from this blog

java - org.apache.http.ProtocolException: Target host is not specified -

java - Gradle dependencies: compile project by relative path -

ruby on rails - Object doesn't support #inspect when used with .include -