Save the output of a command in a logfile. More information: https://manned.org/logsave.
logsave {{path/to/logfile}} {{command}}
logsave {{logfile}} -
logsave -a {{logfile}} {{command}}
logsave -v {{logfile}} {{command}}