Re: Developer manual "tutorials" section?

Raphael Ritz <[email protected]> Thu, 17 Feb 2011 12:31:07 +0100
Newsgroups gmane.comp.web.zope.plone.documentation
Message-ID <[email protected]>
On 2/17/11 12:06 PM, Mikko Ohtamaa wrote:

[..]

>
>> I've been thinking hard on how to do this but no answers yet.
>> For those not aware the community manual on plone.org is actually the
>> result of a conversion process from svn ->  sphinx ->  funnelweb ->
>> plone. The information on where items used to be isn't available to
>> sphinx from svn so it's not possible automate this yet so any renaming
>> in svn won't result in redirects in plone :( Unless someone can think
>> of a clever way to get svn to produce a list of previous paths for
>> each piece of content.
>> The only solution would be to manually reproduce the moves in plone
>> first and then reupload the content overtop.
>>
>
> The conversion process is already little fragile, so I suggest let's not try
> to make it more complicate and we'll just rely on Plone's automatic "Page
> not found - suggestions" feature :)

If the change consists of "only" moving some subtree to a different
location (without changing the structure within the tree) you can
maintain the old links by defining a Python Script (TTW in ZMI in
the parent folder of the moved one) like so:

base = container.absolute_url()
subpath = '/'.join(traverse_subpath)
url = base + <relative path to new location> + subpath
context.REQUEST.RESPONSE.redirect(url)

The script needs to have the same id as the folder that
moved elsewhere. Guess you get the idea.
More of a hack or work-around but functional.

Raphael


>
>
> -----
>
> http://twitter.com/moo9000 Follow me in Twitter
>
>
>
> mFabrik News&ndash; download now for iPhone and Android
>
>
>
> http://bit.ly/mfabrikitunessignaturemoo
> http://blog.mfabrik.com/wp-content/uploads/2011/01/iPhoneFooter.png
>
>
> http://bit.ly/mfabrikandroidsignaturemoo
> http://blog.mfabrik.com/wp-content/uploads/2011/01/AndroidFooter.png
>
>
>



------------------------------------------------------------------------------
The ultimate all-in-one performance toolkit: Intel(R) Parallel Studio XE:
Pinpoint memory and threading errors before they happen.
Find and fix more than 250 security defects in the development cycle.
Locate bottlenecks in serial and parallel code that limit performance.
http://p.sf.net/sfu/intel-dev2devfeb