[Python-Dev] re: The os module, unix and win32

Barry Scott barry at barrys-emacs.org
Tue Jan 13 15:21:09 EST 2004


At 12-01-2004 00:07, Arthur wrote:
>But Thomas (who should know) wrote:
>
> >bdist_wininst can create Windows shortcuts in it's postinstall script.
>
>Thomas (off-list) had also given me a cite to some code, which I haven't had
>the opportunity to try to digest.
>
>Is this a semantic issue as to what can and cannot be done on Windows with
>disutils?
>
>I thought I gathered from Thomas that the functionality he is referencing is
>new as of 2.3.

You could say that we are both right.

Turns out that the key is the special wininst.exe that is used to run the
postinstall script. Its wininst.exe that implements the shortcut code in C
and makes them available to the postinstall script that is its argument.

wininst.exe only implements creating shortcuts a standard library module
would need to implement support reading shortcuts and the other shortcut
actions, resolving(?).

Using win32all you can do everything with short cuts, create, modify, read,
resolve, etc.

Barry





More information about the Python-Dev mailing list