It'd be nice for completion's sake to allow users to access the command passed in, and especially the expanded version that was actually run (with shell wrapper, cd/prefix/etc prefixes, escape characters, etc).
While the plain-jane command should always be accessible in your own code by assigning the expression passed to run, to a variable, this would save people a tiny bit of work; and the debug version of the command is never persisted anywhere, even if printed, and would be handy for auditing, logging or debugging purposes.
Thinking something like return_val.command and return_val.full_command or something like that -- think a bit prior to implementing.
Originally submitted by Jeff Forcier (bitprophet) on 2010-10-06 at 03:18pm EDT
Closing in favor of the pull request issue.
PR got nuked or something, doing this now by hand :) .command and .real_command sound reasonable I think.
Add .command, .real_command to run/sudo retval