delano / rye

Safe, parallel access to Unix shells from Ruby
http://delano.github.com/rye
MIT License
234 stars 32 forks source link

Don't force the output of stderr #49

Closed hlidotbe closed 5 months ago

hlidotbe commented 10 years ago

Let the user handle stderr display if needed when executing commands. It allows for a cleaner output and a better control of what's displayed when building cli applications.

delano commented 10 years ago

The issue here is that some commands (some implementations of ls for example) only print to STDERR and not STDOUT. The idea is that you're seeing everything as you would see it if you were actually logged into the remote machine.

lemmycaution commented 10 years ago

+1

@hlidotbe I tried to install your fork with gem 'rye', git: 'https://github.com/epicagency/rye.git' but bundler gives error below, any idea?

rrno::ENOENT: No such file or directory - /etc/certs/gem-private_key.pem
An error occurred while installing rye (0.9.11), and Bundler cannot continue.

Cheers

hlidotbe commented 10 years ago

@lemmycaution I've updated our fork (which updated this pull request, I'm a noob regarding those kind of stuff) so you should be able to install it from git.

hlidotbe commented 10 years ago

@delano I only comme across your reply, sorry.

If you don't show stdout you're NOT seeing everything as you would see logged in. stderr is not a special case in this regard but just another output channel. If both stdout and stderr where outputted regardless of what someone does with it I'd agree that it would be "as logged in".

lemmycaution commented 10 years ago

@hlidotbe cool, thanks for that. Honestly I preferred to monkey-patch it for using ruby logger instead of stdout/stderr.