Introduction to Computer Science
CompSci 101 : Spring 2014

Software

In order to write programs, you will need some other programs. These allow you to edit your program, translate it into a simpler representation that your computer can understand, and run it. These initial steps may seem a little overwhelming, but they only need to be done once to get things started and working together. This process make take approximately 30 minutes to complete.

This video shows Professor Astrachan installing an older version on a Mac in Fall 2012 (update coming soon!).

When installing these programs, unless otherwise noted, we suggest you simply follow the default installation options.

  1. install Java (so you can run the Eclipse program)
    • the latest version is 7.45 but that one is causing a problem on the Mac, so there we will stick the latest previous version 6.65
    • on Windows: download Oracle's latest version by selecting the option "Free Java Download" from here
    • on Mac: download Apple's latest verion of Java from here
    • double-click the resulting file and follow the default options to install it
    • as an aside, you do not need to allow Java to run in your browser to use it for Eclipse; feel free to disable Java in the browser for security
  2. install Eclipse (an environment for writing and running your software programs)
    • the latest version is 4.3 (nicknamed Kepler)
    • select the first option, "Eclipse Standard 4.3", for your operating system from here
    • choose the 32- or 64-bit version to match the version of Java installed
    • Eclipse is not packaged with an installer; simply unarchive it and move the entire "eclipse" folder to C:\ (Windows) or to Applications (Mac)
  3. install Python (so you can run the programs you write)
    • the latest version of the Python language is 3.3, but we will use 2.7 for this class
    • the distribution we will be using is called Canopy and has a number of bundled packages that will be useful during the semester
    • select "Canopy 1.2" for your operating system from here
    • choose the 32- or 64-bit version to match your particular version of Java and Eclipse
    • double-click the resulting file and follow the default options to install it
    • run Canopy, select the default location for it to install Python, and then quit the program;
      assuming you use Eclipse throughout the rest of the semester, you will not need to run it more than just this once
  4. install the PyDev plugin from within Eclipse (so you can use Eclipse to develop your Python programs)
    • open Eclipse and access the Help menu
    • select "Install New Software..."
    • in the "Work with:" text field, type "http://pydev.org/updates" and press Enter
    • you may need to wait up to a minute until the "Pending..." is replaced by "PyDev" and "PyDev Mylyn Integration (Optional)"
    • select only "PyDev" (by checking the box next to it) and click "Next >" down at the bottom
    • follow the next steps to finish the installation using the defaults and agreeing to the terms and conditions;
      if you receive a warning about unsigned content, proceed anyway
    • at the end, agree to restart Eclipse for changes to take effect
  5. install the Ambient plugin from within Eclipse (so you can download and submit files for class)
    • open Eclipse and access the Help menu
    • select "Install New Software..."
    • in the "Work with:" text field, type "http://www.cs.duke.edu/csed/ambient/update" and press Enter
    • you may need to wait a number of seconds until the "Pending..." is replaced by "Ambient" in the main selection area
    • select "Ambient" and click "Next >" down at the bottom
    • follow the next steps to finish the installation using the defaults and agreeing to the terms and conditions;
      if you receive a warning about unsigned content, proceed anyway
    • at the end, agree to restart Eclipse for changes to take effect
  6. connect Eclipse to your version of Python (so you can run Python programs within Eclipse)
    • open Eclipse and access the Preferences Box (under Window>Preferences on Windows or Eclipse>Preferences on Mac)
    • choose "Pydev" and "Interpreter - Python" from the sidebar
    • press the "New ..." button to tell Eclipse about Python
    • in the resulting dialog box, for the "Interpreter Name" type "Canopy" and for the "Interpreter Executable" type
      • for Windows: "C:\Users\UUU\AppData\Local\Enthought\Canopy\User\python.exe"
      • for Mac: "/Users/UUU/Library/Enthought/Canopy_VVV/User/bin/python"
        where UUU is your user name on your machine and VVV is the remainder of the directory name (which depends on which version you installed; you should be able to find the right one by browsing to it)
    • choose "Select All" and then click "OK" at the bottom of the resulting dialog box
    • click "OK" at the bottom of the Preferences Box and wait for the changes to take effect when the dialog box to close (you do not need to restart Eclipse)