distutils and binding a script to a file extension on windows

Alexandre Guimond ag at mirada-solutions.com
Sat May 13 20:32:00 EDT 2006


Hi.

I built a little installer on windows XP using distutils for my
package. In there i add a few files to the python script directory. I
would like one of these scripts to be the default program to be used by
files with a given extention (e.g. i have an image viewer and would
like it to be used when ever i click on a .gif file). I can do this
manually (through Tools->Folder Options->File Types), but it would be
nicer if the installer could configure this.

It seems this may be possible through the "postinstallation" script of
distutils, but i have no clue how to do this. does any have experience
with this? i assume i need to edit the registry entries, but i dont
know how or which ones.

thx for any help

alex.




More information about the Python-list mailing list