I want to use part of the output of a command run from the command line in another xterm, or as part of a different command. For instance:
> grep error err
The OP said he didn't want to do this, but here is a unix utils way to do it for posterity. If you learn these little unix utilities they can be quite powerful.
ls $( dirname $( grep error error.log | head -1 | cut -d " " -f 5- ) )
note: syntax from memory