[wingide-users] make Wing IDE portable

Wingware Support support at wingware.com
Tue Aug 5 07:23:13 MDT 2008

Crend King wrote:
> I'm trying to make Wing IDE Professional portable so that I can put it
> into a flash drive. First, I tried to find any program parameters to
> support user profile directory redirected, but cannot find anything.
> Then I tried to set USERPROFILE to a sub-directory of WingHome. This
> works, but all dialogs in Wing IDE related to USERPROFILE will be error.
> Then I tried to modify source code. In wing.py, I modified the related
> variable in config module to my profile directory (such as
> config.kUserWingDir). Everything is fine, except I cannot debug in Wing
> IDE now. The reason is, Wing IDE still think the wingdebugpw file should
> be in the USERPROFILE directory, and since it cannot locate it, debug is
> gone.
> Now I located a function,
> debug.tserver.abstract._GetUserWingProfileDir(). It exactly displays the
> USERPROFILE dir. Unfortunately, there is no _SetUserWingProfileDir()
> function.
> I understand modifying the code is bad. I do not have any intention to
> distribute the work, just make it more convenient. Can anyone please
> help me make it? Or will Wing IDE provide user directory redirection?

It's fine to modify the code and your license even explicitly allows you
to distribute the diffs if you want.

That said, this sounds like something we should add general support for.
I'll see if we can do that fairly soon.

In the meantime, I think you've done the right thing on the IDE side.
Can you also modify debug.tserver.abstract to just replace
_GetUserWingProfileDir() with something that returns the correct

BTW, one idea would be to have a script that first copies your
profile dir to the location that unaltered Wing expects it, then
starts Wing, and after Wing quits it copies the dir back to
somewhere on the flash drive.  If that works, it would be cleaner
overall, assuming you don't end up w/ confusion from running
multiple instances of Wing.

Please let me know if that helps or not.



Stephan Deibel
Wingware | Python IDE
Advancing Software Development


More information about the wingide-users mailing list