Greetz fellows!
I’m looking for a way to log actions of a CLI script without losing time. I did some benchmarks and I figured out that by echoing someting after each action, the script will be nearly 2x slower and by appending actions to a log file it’ll be 17x times slower.
So, anyone has a solution?
If you are using CLI, I guess you can test with this:
Inside
YOUR_SCRIPT.phpAnd monitor using
The reason
REMARK 1slow is because function execute first, whileREMAKR 2does not (output first)