Hacker News new | ask | show | jobs
by mandus 6 days ago
One of the things I do with : is infinite while-loops, like:

    while :; do
        <do stuff>
        sleep n
    done

Maybe to mainstream to make the cut!?
1 comments

I prefer using "while true;" as that's easier to read. Arguably, it's less efficient due to calling the external "true".

Strangely though, I much prefer using the builtin "printf" to replace "echo" and "date", though the "date" usage is harder to read.