Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

running external programs in Julia: < command

Tags:

julia

I'm trying to redirect a local script to an external server and need to use the < command in the Julia run() command. I use |> for > in Julia, but |< does not work for <. My question is how can I use the redirect UNIX command < in Julia ?

This is in 0.3.

Thank you

like image 413
Jeremy McNees Avatar asked May 29 '26 08:05

Jeremy McNees


1 Answers

It's not clear for me how to direct STDIN in 0.3.0 ,but only for more clarity, form version 0.4.0 |> is marked as deprecated and is replaced by more robust pipeline function, using pipeline you can direct In|OUT like this:

 run(pipeline(`ls` , stdout="ot.txt"))
 run(pipeline(`sort` , stdin="ot.txt"))
like image 143
Reza Afzalan Avatar answered Jun 02 '26 09:06

Reza Afzalan



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!