-
Notifications
You must be signed in to change notification settings - Fork 13
Description
To enhance the usability and functionality of the idf.py monitor command, it would be beneficial to introduce a new option, --file, that facilitates simultaneous output to both the terminal and a specified log file. This feature is particularly useful for developers who need to analyze logs after running their application or during debugging sessions.
Proposed Feature Description
Option: --file FILENAME
Functionality: When the --file option is used with the idf.py monitor command, the tool should simultaneously display the output in the terminal and write it to the specified file. This dual-output approach allows developers to monitor their application in real-time while also maintaining a record for later analysis.
Example Usage:
idf.py -p PORT monitor --file xpto.txt
In this scenario:
-p PORT specifies the serial port where the ESP device is connected.
--file xpto.txt directs the idf.py monitor tool to write the output to xpto.txt while also displaying it in the terminal.
Benefits
Convenience: Developers can track issues in real-time and have a persistent record without needing to redirect or pipe output manually.
Efficiency: This feature saves time and reduces the complexity of development workflows, especially when diagnosing intermittent issues that require reviewing extended logs.
Consistency: Having a standardized way to log monitor output ensures that developers can reliably capture and share logs across different systems and teams.
This way the CRTL + L could also be used, but the log can be done form the prompt call.