Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support new logging methods with legacy deocrator
Add support for the new log_command_* methods with minimal changes to the existing Formatter code. This is done by decorating the Command object to make it behave like the legacy version that has stderr/stdout methods, filled with the data passed to log_command_data. The other trick is that to avoid calling @log_file_formatter.write within the legacy code, I use a disabling_log_file method to temporarily "mute" the @log_file_formatter within a block. This commit is intended as a stopgap to restore compatibility with with SSHKit @ master until more serious refactoring can be done.
- Loading branch information