What is the easiest way to execute text from tail at the command line?
I was guessing the ouput of a command that fails to execute should be sent to stdout and hence can be piped. It seems I am wrong, so please correct me.
$easy_install The program 'easy_install' is currently not installed. You can install it by typing: sudo apt-get install python-setuptools
So if I want to install with the command suggested, I tried
$easy_install | grep sudo | bash
i.e naively trying to pick out the last line and send it to the shell as a command. I even tried
$easy_install | tail -1 | bash
but get the same blurb without it doing anything. What am I doing wrong?