My attempt:
(import 'java.lang.Runtime)
(. (Runtime/getRuntime) exec (into-array ["youtube-dl" "--no-playlist" "some youtube video link"]))
I also tried sh
. But both approaches don't do what I want - running a program similarly like shell does (sh
waits until program exits, exec
launches it and doesn't wait for its exit; both don't output anything to standard output). I want live showing of process output, e.g. when I run youtube-dl
I want to see progress of a video download.
How to do this simple simple task in Clojure?