Search code examples
sublimetext

how to create a keyboard shortcut for split view (duplicate of the same file) in sublime text


I want to have a keyboard shortcut key for opening the same file in another tab.

this can be done using File>Split view

enter image description here

How can I create a keyboard shortcut for this


Solution

  • { "keys": ["ctrl+u", "ctrl+s"],
      "command": "clone_file",
      "args": {"add_to_selection": true} },
    

    BTW, I found the command's name by typing sublime.log_commands(True) into the console. See OdatNurd's excellent video on this: P101-03 Tools of the Trade: Harnessing the power of the console!