How to connect two shell commands using pipes?
Posted: Mon May 11, 2009 12:03 pm
Hello,
i wanted to make a newLisp app to grab data from an extsting proces. Example:
>> ls /usr/share | grep init
initramfs-tools
initrd-tools
initscripts
As you can see, in the first line I used a "pipe" to connect "ls" command with "grep".
How can I get data input from shell pipe using newLisp (like grep in the previous case)? How can I send data output to shell pipe using newLisp (like ls in the previous case)?
thank you.
i wanted to make a newLisp app to grab data from an extsting proces. Example:
>> ls /usr/share | grep init
initramfs-tools
initrd-tools
initscripts
As you can see, in the first line I used a "pipe" to connect "ls" command with "grep".
How can I get data input from shell pipe using newLisp (like grep in the previous case)? How can I send data output to shell pipe using newLisp (like ls in the previous case)?
thank you.