2

Is there any possible way of assigning this tool to a keyboard shortcut? I'm using this tool because the builtin console in Sublime Text 2 doesn't support interactivity (entering inputs....etc).

this tool

Devid
  • 6,455
  • 13
  • 58
  • 75

1 Answers1

3

See the python menu commands for the package and the q/a: How can I set key bindings for menu items in Sublime Text 2?.

Add to your User keybindings file:

{ "keys": ["ctrl+shift+r"], "command": "repl_open",
                 "caption": "Python - RUN current file",
                 "id": "repl_python_run",
                 "mnemonic": "d",
                 "args": {
                    "type": "subprocess",
                    "encoding": "utf8",
                    "cmd": ["python", "-u", "$file_basename"],
                    "cwd": "$file_path",
                    "syntax": "Packages/Python/Python.tmLanguage",
                    "external_id": "python",
                    "extend_env": {"PYTHONIOENCODING": "utf-8"}
                    }
}

You'll have to do the testing because I don't have that package.

d_rail
  • 2,989