4 ms·
All these neat tricks being discussed, and meanwhile I just `date; my_cmd; date` for jobs I want start/end times of. The fact that I can do it with no configura
by hunter2_ 7y ago
All these neat tricks being discussed, and meanwhile I just `date; my_cmd; date` for jobs I want start/end times of. The fact that I can do it with no configuration on all the umpteen boxes I log into is the reason I stick with it.
- fizixer 7y agoor, if you're only interested in the time it took for the command to run: time my_cmd
- alpaca128 7y agoAll of those are only useful if you thought of it beforehand. Which is rare in my experience, often I want to know the time exactly when something unexpected happened.
- derision 7y agoMost of the time I needed to know when I ran a command, I didn't know I would need it at the time I ran
- stragies 7y agoI have this in my "~/.inputrc": ".,d": "\C-adate; \C-e; date\n" Whenever I want a command dated like in your suggestion, instead of pressing Enter to execute the command, I press the key-sequence ".,d" and the command gets wrapped in 'date' calls.