On Fri, May 16, 2025 at 11:41:00AM -0400, Greg Wooledge wrote:
> On Fri, May 16, 2025 at 08:05:50 -0700, pe...@easthope.ca wrote:
> > Currently have this.
> > ev () { /usr/bin/evince "$@" & }
> > 
> > DISPLAY is set in .bashrc now.  Not needed in trivial functions.
> 
> Why are you setting the DISPLAY variable?  That sounds like a really
> bad idea.  Or, at best, it's only viable in a very specialized setup.

To be more explicit: in the "normal" case, your Xinit (or your desktop
environment) sets that variable. Everything starting from there will
inherit it.

You want to set it

 - if you want things to happen in some other display (you'll need
  access to that one, a whole different story)
 - if you are starting things from "outside" (e.g. DISPLAY=:0 xeyes &
  will start xeyes even called from a Linux console or from an ssh
  session, if other stars align)

Cheers
-- 
tomás

Attachment: signature.asc
Description: PGP signature

Reply via email to