11.04.2013 Views

Guida avanzata di scripting Bash - Portale Posta DMI

Guida avanzata di scripting Bash - Portale Posta DMI

Guida avanzata di scripting Bash - Portale Posta DMI

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

echo 9th, a fd 8 >&8<br />

Appen<strong>di</strong>ce E. Una dettagliata introduzione all’I/O e alla re<strong>di</strong>rezione I/O<br />

) 4>&1 >&3 3>&- | while read a; do echo "FD4: $a"; done 1>&3 5>&- 6>&-<br />

) 5>&1 >&3 | while read a; do echo "FD5: $a"; done 1>&3 6>&-<br />

) 6>&1 >&3 | while read a; do echo "FD6: $a"; done 3>&-<br />

rm -f /tmp/fifo1 /tmp/fifo2<br />

# Per ogni comando e subshell, in<strong>di</strong>cate il fd in uso e a cosa punta.<br />

exit 0<br />

779

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!