gpt-engineer icon indicating copy to clipboard operation
gpt-engineer copied to clipboard

refactor(cli): Move sysinfo formatting into its own function

Open amithadityacp opened this issue 1 month ago • 0 comments

Description

This pull request refactors the --sysinfo command output for better code organization and readability, following the Single Responsibility Principle.

Changes Made

  • Moved the output formatting logic from the main() function directly into the get_system_info() function.
  • The get_system_info() function now returns a fully formatted, multi-line string, making it a self-contained utility.
  • The if sysinfo: block in the main() function is now simplified to a single, clean print() call.

Related Issue

Closes #1194


[!IMPORTANT] Refactors --sysinfo command output by moving formatting logic to get_system_info(), simplifying main() function.

  • Behavior:
    • Refactors --sysinfo command output in main() by moving formatting logic to get_system_info().
    • get_system_info() now returns a formatted string with system details.
    • Simplifies if sysinfo: block in main() to a single print() call.
  • Functions:
    • get_system_info() now includes formatting logic for system information.
  • Misc:
    • Closes issue #1194.

This description was created by Ellipsis for 425521c4d299f3904c1f438beb2432d8118e115b. You can customize this summary. It will automatically update as commits are pushed.

amithadityacp avatar Oct 09 '25 06:10 amithadityacp