bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How do we intercept file saving or output to stdout directly


From: Robert Elz
Subject: Re: How do we intercept file saving or output to stdout directly
Date: Mon, 24 Aug 2020 14:30:18 +0700

    Date:        Sun, 23 Aug 2020 23:17:32 -0700 (MST)
    From:        almahdi <budikusasi@gmail.com>
    Message-ID:  <1598249852364-0.post@n7.nabble.com>

  | How do we intercept and redirect file saving or output to stdout directly in
  | bash, just like e.g
  |
  | xkbcomp $DISPLAY

I think you're just experiencing an oddity with xkbcomp and if
you want to report an issue, it is with the X11 project that you
should be talking, this one has nothing to do with bash.

The problem is that xkbcomp (for whatever reason) wants to
unlink the file it is going to write to before creating a new
one, and, kind of obviously, no matter what magic name you
give, you cannot unlink stdout.

You can however do (or at least, on my system, I can do)

        xkbcomp -o - $DISPLAY

and that seems to work (it is often worth testing whether "-"
works for stdin/stdout when all else has failed - programs
sometimes special case that name).

kre




reply via email to

[Prev in Thread] Current Thread [Next in Thread]