stdout - Display output of a Bash command and keeping the output in a variable -


i'm not sure if possible want run bash command , storing output in variable , display if launched command normally. here code:

var=`svn checkout $url` 

so want store output in var , still see result (and because svn checkout takes long time, can't echo $var after..)

thanks

if command run terminal, can do:

var=$(svn checkout $url | tee /dev/tty) 

Comments

Popular posts from this blog

List<T>().Add problem C# -

Javascript natural sort array/object and maintain index association -