Re: how to know if I'm using xterm or gnome-terminal?

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

 



On Tue, 2010-02-23 at 20:23 +0000, James Wilkinson wrote: 
> Germán A. Racca wrote:
> > How to know if I'm using an xterm or a gnome-terminal from command line?
> > 
> > The output of "echo $TERM" is "xterm" from both of them.
> > 
> > How to know?
> 
> Well, it looks as though gnome-terminal sets $COLORTERM, whereas xterm
> doesn’t. But xterm doesn’t unset it, either, so if you get a user
> starting up a gnome-terminal, thinking “Yuck!”¹ and using that
> gnome-terminal solely to run xterm, then the xterm will inherit the
> $COLORTERM setting.
> 
> Xterm has its own $XTERM_ variables, so you could test for those. But
> gnome-terminal doesn’t unset those, either, so you could get a user
> starting up am xterm, thinking “Yuck!”¹ and using that xterm solely to
> run gnome-terminal…
> 
> And then you’re going to get someone using Konsole.
> 
> What are you trying to do?
> 
> James.
> 
> ¹There’s no accounting for taste…
> 
> -- 
> E-mail:     james@ | I must refute the rumour that one of our team members
> aprilcottage.co.uk | walks on water. Although it’s true that Barry Cryer runs
>                    | on lager...
>                    |     -- “I’m Sorry, I Haven’t A Clue”, BBC Radio 4

I'm running a program called IRAF to work with astronomical images, and
it needs to use the graphic capabilities of an xterm, not
gnome-terminal. So, I'm trying to make a very simple script to start
IRAF, but first I have to know if I'm on an xterm (so it enters directly
to IRAF) or a gnome-terminal (in this case the script must open an xterm
before).

Germán.

-- 
Germán A. Racca
National Institute for Space Research (INPE)
São José dos Campos - SP - Brasil
http://sites.google.com/site/gracca
http://gracca.wordpress.com

-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines

[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [Fedora Magazine]     [Fedora News]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Maintainers]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Legacy]     [Fedora Desktop]     [Fedora Fonts]     [ATA RAID]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [SSH]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Centos]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Tux]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Asterisk PBX]     [Fedora Sparc]     [Fedora Universal Network Connector]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux