collective.recipe.updateplone won't work on Windows

Bug #302584 reported by danilogbotelho on 2008-11-26
Affects Status Importance Assigned to Milestone

Bug Description

It seems that updateplone expects to be run solely on Linux.
On Windows the instance controller is bin\instance.exe, with the .exe extension.
Besides, all file paths should have backslashes doubled or converted to forward slashes ('/') lest some character pairs get wrongfully translated into single escaped characters like '\n', '\r' and '\a'!

Patch is as easy as inserting lines:

if sys.platform == 'win32':
                instance_ctl += '.exe'

and appending replace("\\","/") like this:

#third, generate a temporary script
recipe_egg_path = os.path.dirname(__file__)[:-len(self.options['recipe'])].replace("\\","/")
template_file = os.path.join(os.path.dirname(__file__), 'script.py_tmpl').replace("\\","/")
tmp_file = tempfile.mktemp().replace("\\","/")

danilogbotelho (danilogbotelho) wrote :
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers