When a GUI program malfunctions in some way (crashes, etc.) I often use the trick of running it from the command line (instead of from the menu). That way I see the messages it outputs to stdout
and stderr
which sometimes gives me a clue as to what went wrong (or at least a message I can Google to take me further down the "solution path").
Is there any way I can get all GUI programs to save their stdout
and stderr
somewhere so I can diagnose problems without having to start them from the command line? Not only would this be more convenient, it would help users who don't know about this trick.
You mean, like the existing
~/.xsession-errors
log?Unfortunately it tends to get filled with lots of warnings & other useless messages.
For a particular menu command, you can change the command that start the application, for example with
alacarte
in gnome, to become something similar to:where
~/log
is a directory previously created, andcommand
should be substituted with a real command name.If that do not work, embed the command in a shell invocation:
Unfortunately, I fear there is no general solution.