The UNIX and Linux Forums  


Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #5 (permalink)  
Old 02-11-2009
metaltree metaltree is offline
Registered User
  
 

Join Date: Feb 2009
Location: Québec city
Posts: 4
Thanks, but apparently this goes beyond the Cygwin element.

I tried that on a Linux bash:

1. Works fine as a line:

Code:
-bash-3.1$ cat <(printf "aaa\nbbb\n") <(printf "111\n222\n")
aaa
bbb
111
222

2. Won't work as a script:

Code:
 
-rw-r--r-- 1 cleseb01 cleseb01 51 Feb 11 16:27 script
-bash-3.1$ cat script 
cat <(printf "aaa\nbbb\n") <(printf "111\n222\n")
 
-bash-3.1$ sh script 
script: line 1: syntax error near unexpected token `('
script: line 1: `cat <(printf "aaa\nbbb\n") <(printf "111\n222\n")'