5 ms·
Same here back in the early aughts, but it took me a while to really dig in and discover that units also handles times too. e.g. units "sec $(echo $SECONDS)" "
by lozf 6y ago
Same here back in the early aughts, but it took me a while to really dig in and discover that units also handles times too.
e.g. units "sec $(echo $SECONDS)" "day;hr;min;sec"
- philjackson 6y agoUseless use of echo there.
- ttul 6y agoNot unless you’re also trying to demonstrate the magic of fork.
- lozf 6y agonoted, thanks
- techbio 6y agoExtraneously strenuous use of "useless" when using "redundant" would have done...unless useless has another usage. EDIT: The commenter echoed, duckly.
- x0 6y agoIt's very important to watch out for useless uses of echo/cat. What is cat, a few megabytes now? Fine for those of us on modern hardware, but you never know what PDP-11 user is going to copy paste your comment into their terminal.
- watersb 6y agoI use a construct like this to ensure that the value ends with a newline.
- smorrow 6y ago$() chomps the newline though...