views:

70

answers:

2

I'm creating one-click python installer (integrated with my application). Is there any way to force Python MSI installer to add python's path to SYSTEM PATH variable? I'm using MSI installer because it is very easy to specify (using command line) how it should interact with the user.

A: 

There has to be a way, but what some people do is provide batch files that set up the environment before invoking Python. That's what BZR does, anyway. If you can write that batch file somewhere that's already normally in the path, so much the better.

If you're just worried about invoking Python, the normal Python installer does file associations, so you can work it that way.

Ian
A: 

User variables are stored in the Windows Registry under HKEY_CURRENT_USER\Environment

I would use winreg in a post install script to set or add to the PATH there.

http://docs.python.org/library/_winreg.html

Rawheiser