mklement0 / ttab

macOS and Linux CLI for opening a new terminal tab/window, optionally with a command to execute and/or display settings
283 stars 15 forks source link

Setting tab title in OS X Ventura with Terminal app does not set the title #65

Closed rantler closed 1 year ago

rantler commented 1 year ago

When invoking the command below:

ttab -d ~/Developer/docker_es -g -t 'Docker ES' docker-compose up es01

The tab opens and briefly sets the title to "Docker ES", after which the title is immediately replaced with "cd /Users/username/Developer/docker_es".

I've turned off all of the Terminal preferences that relate to Window to Tab titles.

Am I doing it wrong?

mklement0 commented 1 year ago

I don't use docker, but in principle it seems to work for me in Ventura (13.5.2) in Terminal.app:

ttab -d ~/Desktop -g -t 'Desktop ES' date

shows the following tab title, with either /bin/bash or /bin/zsh as the default shell:

image

When you run this, do you see a different result?

rantler commented 1 year ago

It does the same thing; it briefly displays "Desktop ES" in the title, then immediately displays "~/Desktop".

rantler commented 1 year ago

I should mention also that if I manually set the tab title after it has opened, then the title remains until I perform some command, after which the title is replaced with the command that I performed.

I'm starting to think this is a bug with the Terminal app itself. 😩

mklement0 commented 1 year ago

I don't see the same symptoms when I run programs such as date or even when I invoke another shell - are you sure the problem isn't specific to docker-compose up?

rantler commented 1 year ago

This is likely due to my using zsh and a custom prompt. If I switch to bash, ttab works as expected. Sorry for the false alarm.

On Fri, Sep 29, 2023 at 9:43 AM Michael Klement @.***> wrote:

I don't see the same symptoms when I run programs such as date or even when I invoke another shell - are you sure the problem isn't specific to docker-compose up?

— Reply to this email directly, view it on GitHub https://github.com/mklement0/ttab/issues/65#issuecomment-1741195931, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAASAL42VG5G7QILWWFQC6TX433DHANCNFSM6AAAAAA5LSYBE4 . You are receiving this because you authored the thread.Message ID: @.***>

--

Randy Antler Senior Software Engineer Fountain, Incorporated

mklement0 commented 1 year ago

No worries, glad you found the cause.