Previous Section  < Day Day Up >  Next Section

true—provides successful exit status

true does nothing, successfully, meaning that it always returns a 0 exit status, indicating success. Used in Bourne and Korn shell programs as a command to start an infinite loop.


while true

do

   command

done


    Previous Section  < Day Day Up >  Next Section