On Thu, 19 Aug 2010 18:16:24 +1000
"Trent W. Buck" <trentb...@gmail.com> wrote:

> >> It would be nice if this could be elided, with a --quiet option.
> > Exactly what output are you seeking to remove?
> 
> I was mainly thinking of passing -q or -qq on to apt-get.

OK.
 
> > However, multistrap operations take an appreciable amount of time and
> > some form of user feedback is essential.
> 
> Granted, when the user is sitting there watching it.
> 
> The use case I have in mind is when I run multistrap from a cron job,
> or just kick off a build, go have lunch, then come back and read the
> output.  I want to reduce the amount of "I'm working!" output so that
> any "I'm NOT working!" output will stand out.
>
> I tried simply discarding stdout, and this appears to work.  Usually
> I'm too nervous to do that, because so many programs are ill-behaved
> and print errors to stdout.  Fortunately, apt-get and dpkg behave :-)

(This is one of the many very good reasons to use dpkg and apt via
multistrap instead of reimplementing that functionality inside
debootstrap.) :-)

The only time multistrap explicitly puts something onto stderr is if
the command line options cannot be parsed, at which point multistrap
will exit with an error and you get the desired indication that the
operation simply has not worked.

:-)
 
> > [...] Progress indicators are ugly but letting the script appear to
> > hang is worse. If that is what you expect, I will have to close this
> > bug as wontfix.
> 
> While I agree that progress indicators should be on *by default*, I
> think it should be possible to opt-out of them in batch runs.
> 
> Since we disagree, I've WONTFIXed this ticket; I'll simply set my
> batch jobs to redirect stdout from multistrap to /dev/null.

Sure, that's a valid and supported method of using multistrap for a
cron task or similar. (We aren't in disagreement that much. In effect,
any --quiet option to multistrap would simply encode 1>/dev/null into
the script itself, so the methods are equivalent.)

Multistrap will continue to respect the stdout/stderr division and exit
non-zero if something goes badly wrong  - if it doesn't that would be a
Severity: important bug.

Again, if you feel this should be included in the documentation, feel
free to retitle the bug and I'll fix the docs.

-- 


Neil Williams
=============
http://www.data-freedom.org/
http://www.linux.codehelp.co.uk/
http://e-mail.is-not-s.ms/

Attachment: pgpDUSy79mwgf.pgp
Description: PGP signature

Reply via email to