You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As well as recording the command and the time, it would useful if tcsh could also record the "$status" (AKA "$?") returned by each command.
This would allow the user to see not just what commands have been run, but which ones had an effect or not.
For example, history could display an extra column, with perhaps one character for success and a different character for failure.
Personally, I like to use "/" for success, because it reminds me of a tick, and I use "X" for failure. But maybe that's just me.
Another option would be to display the actual numeric status, or to display "X" for failure and a blank " " for success.
Without having checked the existing codebase, I see two potential issues:
if the history list is updated when the command is issued, then it would need to be modified when the command has succeeded/failed.
if there is a need to preserve the format of the .history file, then some alternate way of storing the status codes would be needed.
If people might be prepared to consider such a feature (and it could of course be implemented as optional), then I am prepared to investigate and see if I can produce a working proof-of-concept.
The text was updated successfully, but these errors were encountered:
suominen
changed the title
(wish) History would record success/failure of each request
Make history record success/failure of each command
Nov 17, 2021
suominen
changed the title
Make history record success/failure of each command
Make history record success/failure of each entry
Nov 17, 2021
As well as recording the command and the time, it would useful if tcsh could also record the "$status" (AKA "$?") returned by each command.
This would allow the user to see not just what commands have been run, but which ones had an effect or not.
For example, history could display an extra column, with perhaps one character for success and a different character for failure.
Personally, I like to use "/" for success, because it reminds me of a tick, and I use "X" for failure. But maybe that's just me.
Another option would be to display the actual numeric status, or to display "X" for failure and a blank " " for success.
Without having checked the existing codebase, I see two potential issues:
If people might be prepared to consider such a feature (and it could of course be implemented as optional), then I am prepared to investigate and see if I can produce a working proof-of-concept.
The text was updated successfully, but these errors were encountered: