2021 April

Bash Loops

Examples of various looping scripts using bash Arrays and Counts Loop through an incremental count for INDEX in {0..5}; do echo $INDEXdone# one linerfor I in {0..5}; do echo $INDEX; done   Files Looping through items in a file Using cat for ITEM in `cat FILE.NAME`; do echo $ITEM done #one liner for ITEM in… read more »

Sidebar