Search code examples
pythonmacospython-idle

Shortcut to python IDLE on mac os


I want to create a shortcut for IDLE on my mac so that I don't need to go through the terminal. Is there a way to do this? I was trying Automator but I'm not that familiar with it.

Thanks.


Solution

  • You can use a shell script to do what you need on osx.

    Instructions to open a python interpreter in terminal:

    • First create a file called python.command
    • Open the file in any text editor and copy and paste the following

      #!/bin/bash

      python

    • If you want to open the IDLE Standalone App do the following (repeat step 1,2 but paste the following) but make sure your path is correct:

      #!/bin/bash

      open -a /Applications/Python\ 2.7/IDLE.app