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

Re: gnome-terminal question



On Mon, Feb 12, 2001 at 07:09:24PM -0500, D-Man wrote:
> On Mon, Feb 12, 2001 at 02:19:20PM -0800, aphro@portal.aphroland.org wrote:
> | 
> | hi
> | 
> | 
> | i was curious what needs to be done to get a remote host
> | (connected through ssh) to display the hostname and directory
> | in the titlebar of a gnome-terminal window. redhat systems
> | seem to do this but none of my debian systems do.
> | 
> 
> What I had done was make some launchers (shell scripts work as well)
> for each of the hosts I would connect to and use the command line to
> set the title.  (I think the opiton is -t) 

make it -T

> I think there is some (shell) command that can be used as well (from

yep, echo:) 

    $ echo -en "\033]0;My brand new title\007"

More from the list-archives (to be put in your ~/.bashrc file):

    # Following sets prompt to [userid@host dir], and puts the full
    #   user@host:/full/path/spec in an xterm title bar.
    function proml
    {
    case $TERM in
        xterm*|rxvt|eterm|wterm)
            local TITLEBAR='\[\033]0;\u@\h:\w\007\]'
            ;;
        *)
            local TITLEBAR=''
            ;;
    esac

    PS1="${TITLEBAR}\
    [\[\033[7m\]\u\[\033[0m\]@\h:\W]\
    \$ "
    PS2='> '
    PS4='+ '
    }


My question back is:
how the hell are you supposed to find such info?
nothing in term/info-cap.

-- 
groetjes, carel



Reply to: