Re: [Zope] zexp import fails from linux to windows due to image filepaths

2008-07-17 Thread Tim Nash
You can use this to edit the zexp on the command line. It is from the
cygwin build system.

perl -pe 'BEGIN{binmode(STDIN); binmode(STDOUT);};
s/oldtext/newtext/g'   copy_of_your.zexp   fixed_copy_of_your.zexp

then rename fixed_copy_of_your.zexp to the original zexp name and
import it into a NON-Production version of zope.

I have used this to edit binary data but I've not tried the zexp
import. Be careful because it looks like ExportImport.py in ZODB will
try to register any python pickle that begins with ZEXP.  This could
really mess up your data.

Unfortunately there doesn't seem to be many zexp manipulation scripts available.

Good luck!
Tim


On 7/16/08, Richard Ettema [EMAIL PROTECTED] wrote:
 Quoting Jaroslav Lukesh [EMAIL PROTECTED]:


 You need to export your website folder as ZEXP in XML format. Then you
 could edit this file at search/replace basis. But before this, try to
 re-import this ZEXP file, if it is able to import (not all zexp exports
 are able to reimport).

 Regards, JL.

 Thanks for the reply JL, re-importing into the original server and
 exporting in XML is not an option as I don't have the server anymore,
 only a Windows machine.
 If editing the existing ZEXP is not possible, is it possible to modify
 the actual zope code temporarily, to ignore the mismatch of file paths
 (or to modify the paths from linux to windows during the import
 process)?
 Thanks, Rich

 ___
 Zope maillist  -  Zope@zope.org
 http://mail.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
  http://mail.zope.org/mailman/listinfo/zope-announce
  http://mail.zope.org/mailman/listinfo/zope-dev )

___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] zexp import fails from linux to windows due to image filepaths

2008-07-16 Thread Jaroslav Lukesh

From: Richard Ettema [EMAIL PROTECTED]
with windows for development. Is there a way of getting the import 
procedure to ignore the errors and continue the import (i.e. any hints  on 
how to modify the zope code)? Or is there a way to edit the zexp to  do a 
search  remove/replace of the file path names so the import  completes 
with no file path details?


You need to export your website folder as ZEXP in XML format. Then you could 
edit this file at search/replace basis. But before this, try to re-import 
this ZEXP file, if it is able to import (not all zexp exports are able to 
reimport).


Regards, JL. 


___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] zexp import fails from linux to windows due to image filepaths

2008-07-16 Thread Richard Ettema

Quoting Jaroslav Lukesh [EMAIL PROTECTED]:



You need to export your website folder as ZEXP in XML format. Then you
could edit this file at search/replace basis. But before this, try to
re-import this ZEXP file, if it is able to import (not all zexp exports
are able to reimport).

Regards, JL.


Thanks for the reply JL, re-importing into the original server and  
exporting in XML is not an option as I don't have the server anymore,  
only a Windows machine.
If editing the existing ZEXP is not possible, is it possible to modify  
the actual zope code temporarily, to ignore the mismatch of file paths  
(or to modify the paths from linux to windows during the import  
process)?

Thanks, Rich

___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce

http://mail.zope.org/mailman/listinfo/zope-dev )