Open main menu

CDOT Wiki β

Changes

BASH Flow Control

160 bytes added, 12:25, 19 September 2008
while
Executes ''commands'' once for each time that ''pipeline'' returns a true result (exit code of zero). Example:
!!!!!!!!! Need example !!!!!!!!!!num=1 while [ $num -le 5 ] do echo $num num=$[ $num + 1 ] doneIn this case it will just print number 1 to 5   while (( 1 )) do eject -T doneTry executing this script on your pc
= for (list) =
1
edit