tdenniston / bish

Bish is a language that compiles to Bash. It's designed to give shell scripting a more comfortable and modern feel.
MIT License
1.48k stars 36 forks source link

Bish does not support I/O redirection #11

Open tdenniston opened 9 years ago

tdenniston commented 9 years ago

Should be able to do e.g. ls | grep foo in bish.

ypersyntelykos commented 9 years ago

i dont understand

tdenniston commented 9 years ago

Well, one of the most powerful primitives in bash (or any sort of shell) is redirection of input/output between processes. It's the "Unix philosophy": write lots of small programs that perform one job, and stitch them together with I/O redirection. Thus, bish must support these operations.

ls | grep foo simply means list files, but instead of printing the listing to the screen, redirect that output into the input of the grep tool. That's what the pipe character | means. Then grep is given a pattern to match, and prints all matches to the screen.

pketh commented 9 years ago

+1

tdenniston commented 9 years ago

Punting on this issue so I can do a 0.1 release.