[Tutor] Windows, Python and me
Sun, 12 Aug 2001 22:35:37 +0100
I'll jump in here - probably with both feet!
> >> 1. After installing Python under Windows, I can't
> >> just type "python"
You should - provided you've done a reboot. I'm sure the
official pythomn installeer sets both the path and the
If not you need to either set the PATH env var in autoexec.bat
yourself(via the installer) or tell the user how...
But they need the reboot to pick up the new setting!
Once thats done they don't even need to type Python at
the DOS prompt they can just double click the .py files
in Windows Exploder
> >This is how to initiate an interactive Python session from the "DOS"
> >command prompt:
Or indeed go to Start|Run and just type "python"
...or "foo.py" or whatever!
> And what could you say about adding
> to the C:/WINDOWS/COMMAND
> directory with proper python call and all arguments re-applied?
Bad idea! For a start DOS BAT can only handle 9
arguments (%1...%9) ata time(like unix you can shift them but how could the
script do that sensibly???
So if someone created a python script that took 9 it would fail
C:> python f.py 1 2 3 4 5 6 7 8
would internally call python.bat which would do
python f.py 1 2 3 4 5 6 7 8
using python.exe but losing one arg in favor of the script name...
> (I am not sure what is the MS equivalent of bash's $*, though...)
There isn't one!
You could of course create a WSH script that would work
since WSH uses an "Arguments" COM collection...
> >> 2. Some tar.gz archives are using LF-line ends
Isn't there a default script in the python distro for
converting Unix-SDOS line ends?
crlf.py or something?
> WinZip is not free.
No but Zip Central is and is a winzip clone.
Do a search or visit my tutor which has a web link.