source: win32_postinstall.py @ 694:ee364596c341

Revision 694:ee364596c341, 432 bytes checked in by Kirk McDonald <kirklin.mcdonald@…>, 10 years ago (diff)

Win32 postinstallation script. (Adds shortcut to examples to desktop.)

Line 
1import os, os.path
2import sys
3import distutils.sysconfig as sysconfig
4
5desktop = get_special_folder_path("CSIDL_DESKTOPDIRECTORY")
6shortcut = os.path.join(desktop, 'PySoy Examples.lnk')
7examples = os.path.join(sysconfig.get_python_lib(True), 'soy', 'examples')
8
9if sys.argv[1] == '-install':
10    create_shortcut(examples, "PySoy Examples", shortcut)
11else:
12    if os.path.exists(shortcut):
13        os.remove(shortcut)
14
Note: See TracBrowser for help on using the repository browser.