@cmd('<STR_LIT>', options='<STR_LIT>')<EOL>def select_window(pymux, variables):
window_id = variables['<STR_LIT>']<EOL>def invalid_window():<EOL><INDENT>raise CommandException('<STR_LIT>' % window_id)<EOL><DEDENT>if window_id.startswith('<STR_LIT::>'):<EOL><INDENT>try:<EOL><INDENT>number = int(window_id[<NUM_LIT:1>:])<EOL><DEDENT>except ValueError:<EOL><INDENT>invalid_window()<EOL><DEDENT>else:<EOL><INDENT>w = pymux.arrangement.get_window_by_index(number)<EOL>if w:<EOL><INDENT>pymux.arrangement.set_active_window(w)<EOL><DEDENT>else:<EOL><INDENT>invalid_window()<EOL><DEDENT><DEDENT><DEDENT>else:<EOL><INDENT>invalid_window()<EOL><DEDENT>
Select a window. E.g:  select-window -t :3