nikhilgupta10 / GridLAB-D

Other
1 stars 0 forks source link

#871 Smart wrap help and other regular output so it doesn't overrun right side of window, #2597

Open nikhilgupta10 opened 8 years ago

nikhilgupta10 commented 8 years ago

When outputting to some shells, the right side doesn't wrap in a very legible manner. Smart wrapping would be highly beneficial in these cases. For example

host% gridlabd --help
Syntax: gridlabd [<options>] file1 [file2 [...]]

Command-line options
--------------------
  --check|-c                                      Performs module checks before starting simulation
  --debug                                         Toggles display of debug messages
...

really should be output as

host% gridlabd --help
Syntax: gridlabd [<options>] file1 [file2 [...]]

Command-line options
--------------------
  --check|-c                                      Performs module checks before 
                                                  starting simulation
  --debug                                         Toggles display of debug messages
...
~~~~~,
nikhilgupta10 commented 8 years ago

nikhilgupta10 imported these comments from Sourceforge: The user dchassin does not exist anymore. Therefore assigning this to afisher1. "dchassin":Recommend this be addressed in 4.0. This might be more difficult than seems at first blush. The output_* function will probably have to be enhanced with special codes to give it hints about formatting (i.e., indent location using >>> and wrapping edge location using the window size info or <<< for direct encoding). This is probably a 1 or 2 day coding and documentation effort but validation will be a headache because it requires visual inspection of output to be certain it works correctly. One nice thing is that the special code are not likely to interfere with existing functionality so this should be completely backward compatible if design with some thoughtfulness.,