Re: [Tutor] Running Existing Python

2011-02-27 Thread Dave Angel
On 02/27/2011 02:50 AM, Justin Bonnell wrote: On Feb 26, 2011, at 10:51 PM, Dave Angel wrote: On 02/26/2011 06:03 PM, Justin Bonnell wrote: On Feb 26, 2011, at 4:05 PM, Dave Angel wrote: As for cd not working, someone else has pointed out that in the shell, you need to escape certain

Re: [Tutor] Running Existing Python

2011-02-26 Thread ALAN GAULD
--This is the location of the file: > > >/jwbonnell/bin/Python 2.7/Extras/Demo/tkinter/guido/hello.py > > >but it still says it cannot find the directory when I try to run it or cd to >it. > >As an obvious beginner with the shell the easiest way to change folder is MacOS is to use the Finder.

Re: [Tutor] Running Existing Python

2011-02-26 Thread Steven D'Aprano
Justin Bonnell wrote: --My current working directory is not what I have been trying to cd to, so I'm assuming that I am using the cd command wrong. You don't need to cd into the current working directory. You're already there. That's what "working directory" means -- the directory you just

Re: [Tutor] Running Existing Python

2011-02-26 Thread Corey Richardson
On 02/26/2011 04:32 PM, Justin Bonnell wrote: > --My current working directory is not what I have been trying to cd to, so > I'm assuming that I am using the cd command wrong. > > I have tried: > > $ cd /jwbonnell/bin/Python\2.7/Extras/Demo/tkinter/guido > $ cd /jwbonnell/bin/Python\2.7/Extras/

Re: [Tutor] Running Existing Python

2011-02-26 Thread Justin Bonnell
On Feb 26, 2011, at 3:18 PM, Corey Richardson wrote: > On 02/26/2011 04:10 PM, Justin Bonnell wrote: > >> --This is the location of the file: >> >> /jwbonnell/bin/Python 2.7/Extras/Demo/tkinter/guido/hello.py >> >> but it still says it cannot find the directory when I try to run it or cd

Re: [Tutor] Running Existing Python

2011-02-26 Thread Steven D'Aprano
Justin Bonnell wrote: --This is the location of the file: /jwbonnell/bin/Python 2.7/Extras/Demo/tkinter/guido/hello.py I doubt that. Mac OS is a type of Unix, and it would shock me if it puts home directories (the jwbonnell/ part) directly under the file system root / My guess i

Re: [Tutor] Running Existing Python

2011-02-26 Thread Walter Prins
On 26 February 2011 21:18, Justin Bonnell wrote: > --I tried to follow this using: > /jwbonnell/bin/Python 2.7/Extras/Demo/tkinter/guido/hello.py > which is the correct location of the hello.py file. > Try putting quotes around the full path. The problem is that the space between "Python" and "2

Re: [Tutor] Running Existing Python

2011-02-26 Thread Dave Angel
On 02/26/2011 04:10 PM, Justin Bonnell wrote: On Feb 26, 2011, at 4:49 AM, Dave Angel wrote: On 01/-10/-28163 02:59 PM, Justin Bonnell wrote: Okay. When I try to run the script from the terminal, it still doesn't work. Here is a screenshot. What am I doing wrong? 1) You're top-posting

Re: [Tutor] Running Existing Python

2011-02-26 Thread शंतनू
On 27-Feb-2011, at 2:40 AM, Justin Bonnell wrote: > On Feb 26, 2011, at 4:49 AM, Dave Angel wrote: >> 3) You don't tell us where the hello.py file actually is. Presumably it's >> not in the current directory when you run that. Two cures for that: either >> specify its real location, >> p

Re: [Tutor] Running Existing Python

2011-02-26 Thread Justin Bonnell
-This is the correct for my computer: /Library/Frameworks/Python.framework/Versions/2.7/bin/python > > and copy the output instead of /usr/env > > > Alan Gauld > Author of the Learn To Program website > http://www.alan-g.me.uk/ > > > > > ----- Original Messa

Re: [Tutor] Running Existing Python

2011-02-26 Thread Corey Richardson
On 02/26/2011 04:10 PM, Justin Bonnell wrote: > --This is the location of the file: > > /jwbonnell/bin/Python 2.7/Extras/Demo/tkinter/guido/hello.py > > but it still says it cannot find the directory when I try to run it or cd to > it. Is there any way that I can tell which directory the

Re: [Tutor] Running Existing Python

2011-02-26 Thread Justin Bonnell
On Feb 26, 2011, at 4:49 AM, Dave Angel wrote: > On 01/-10/-28163 02:59 PM, Justin Bonnell wrote: >> Okay. When I try to run the script from the terminal, it still doesn't work. >> Here is a screenshot. >> >> >> >> >> >> What am I doing wrong? >> > 1) You're top-posting. Put your response

Re: [Tutor] Running Existing Python

2011-02-26 Thread Steven D'Aprano
Justin Bonnell wrote: Okay. When I try to run the script from the terminal, it still doesn't work. Here is a screenshot. Please don't send screenshots except as a last resort. Just copy and paste the error message -- it is ordinary text in a terminal window. The error seems pretty straight-

Re: [Tutor] Running Existing Python

2011-02-26 Thread Dave Angel
On 01/-10/-28163 02:59 PM, Justin Bonnell wrote: Okay. When I try to run the script from the terminal, it still doesn't work. Here is a screenshot. What am I doing wrong? 1) You're top-posting. Put your responses after the quote you're responding to. 2) You're trying to include graphic

Re: [Tutor] Running Existing Python

2011-02-26 Thread ALAN GAULD
an Gauld > Cc: tutor@python.org > Sent: Saturday, 26 February, 2011 6:49:37 > Subject: Re: [Tutor] Running Existing Python > > Okay. When I try to run the script from the terminal, it still doesn't work. >Here is a screenshot. > > > What am I doing wrong? &

Re: [Tutor] Running Existing Python

2011-02-26 Thread Justin Bonnell
Okay. When I try to run the script from the terminal, it still doesn't work. Here is a screenshot. <> What am I doing wrong? On Feb 25, 2011, at 6:46 PM, Alan Gauld wrote: > > "Justin Bonnell" wrote > >> Python 2.7.1 (r271:86882M, Nov 30 2010, 10:35:34) [GCC 4.2.1 (Apple Inc. >> build 5664

Re: [Tutor] Running Existing Python

2011-02-25 Thread Alan Gauld
"Justin Bonnell" wrote Python 2.7.1 (r271:86882M, Nov 30 2010, 10:35:34) [GCC 4.2.1 (Apple Inc. build 5664)] on darwin Type "copyright", "credits" or "license()" for more information. The >>> prompt means you are already inside Python. You can type Python commands at the >>> prompt, thing

Re: [Tutor] Running Existing Python

2011-02-25 Thread Corey Richardson
On 02/25/2011 06:42 PM, Justin Bonnell wrote: > I downloaded Python 2.7.1. I think this is a pretty basic question. > When I try to run the existing python files on the computer (hello.py), I > receive a syntax error. > > Python 2.7.1 (r271:86882M, Nov 30 2010, 10:35:34) > [GCC 4.2.1 (Apple Inc