Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Using Ubuntu I can create a terminal with two tabs: gnome-terminal --tab --tab

However, by default it goes to the last created tab. Using Alt + 1 I can make it go to the first, but I want to avoid key presses.

I'd like to either create an alias to execute Alt + 1 in bash, or directly insert similar code: gnome-terminal --tab --tab -e "alt1"

Any ideas?

share|improve this question

migrated from Jul 4 '10 at 21:49

This question came from our site for professional and enthusiast programmers.

This works but it's a bit kludgey and requires xdotool:

gnome-terminal --tab --tab --tab -e 'xdotool key alt+1'
share|improve this answer

You must log in to answer this question.