Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setting tab name with echo #144

Open
robertmarkbram opened this issue Mar 11, 2024 · 1 comment
Open

Setting tab name with echo #144

robertmarkbram opened this issue Mar 11, 2024 · 1 comment

Comments

@robertmarkbram
Copy link

robertmarkbram commented Mar 11, 2024

I am trying to run a command to set a tab/pane name (not sure which is which atm) using echo.

windows:
  - name: Run-apps
    root: ~
    layout: tiled
    panes:
      - commands:
        - echo -e '\033];My tab name\007'
        - cd ~/my-app

When I run this I get:

200:201: syntax error: Expected “"” but found unknown token. (-2741)

Any way to make this work as I expect?

Rob
:)

@robertmarkbram
Copy link
Author

robertmarkbram commented Mar 12, 2024

Solved this with a script.

      - commands:
        - renameConsole.sh "New name"

The script is hacky because I noticed that sometimes the rename just doesn't work (some timing issue I guess).. but like all good IT solutions clicking the button over and over solves everything:

#!/bin/bash

sleep 2
echo -e "\033];${1}\007"

sleep 2
echo -e "\033];${1} 2\007"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant