

Choose any modifier key that you want to be part of the keystroke, and then select from the drop-down list to assign a hotkey. Call the command name anything you like, preferably something relevant like “Run in Python,” as seen in the image.Ģ. “execfile(‘$(FULL_CURRENT_PATH)’)” is the python function that loads and runs the python file you are editing, while $FULL_CURRENT_PATH is Notepad++’s way of passing the file path of the file you were editing when you ran this command.ġ.

-c is the option that allows you to run the python code in double quotes immediately following the option flags.-i is the option that puts the command line into the “interactive mode” of python after the code is run, which will make the workflow resemble IDLE better.


NOTE: This article is designed to complement the Python: The Basics course offered by IT Training at IU, but serves as an independent resource as well. This article demonstrates how to set up Notepad++ to load and run your python document into the python interpreter with the flick of a custom keystroke. While there is nothing wrong with writing and executing python code in IDLE, python’s bundled integrated development environment, sometimes you might prefer to write in a more standard editor.
