I am trying to rename opened terminal tabs in OSX, but I can only change the Terminal title with the code below. Is there a way to change the Tab title with command? I am using osascript with python 2.7.
name = """osascript -e 'tell application "Terminal" to set custom title in selected tab of the front window to "script_1"'"""
os.system(name)
Manually: Shell > Edit Title(SHIFT+COMMAND+I) > Tab Title