[Zope3-dev] How to structure different related packages

Florian Lindner mailinglists at xgm.de
Sun Oct 3 04:24:23 EDT 2004


Stephan Richter schrieb:

>On Saturday 02 October 2004 07:59, Florian Lindner wrote:
>  
>
>>I think b is the best one and they packages are also uniquely
>>destinctable with dotted names. Is there really no problems doing it
>>like that? What is the preferred way of grouping packages with all
>>belong together?
>>    
>>
>
>Yes, option (b) is the recommended way, so that you have unique dotted names. 
>BTW, if you want to follow the Zope 3 style guide you make your modules all 
>lower case. Module names should be short, preferably only one word or 
>acronym.
>
Ok.
I've now created my directory CS with the subdirs User and Event. It's 
working fine.

Now I want to add a ressource styles.css which should be used by all 
subpackages. I created a directory ressource, places the styles.css and 
a __init__.py in it and included it.
First problem:
My configure.zcml in ./ressources looks like that:

<configure xmlns="http://namespaces.zope.org/zope">
    <resource name="styles.css" file="styles.css" layer="centershock" />
</configure>

But zope is complaing about a missing type argument. apidoc says:

*|type|* - |GlobalObject| 
<http://localhost:8080/++apidoc++/Class/zope/configuration/fields/GlobalObject/index.html> 
(required, default = |None|)

could it be possiblee, that there is something wrong in your book? In 
http://dev.zope.org/Wikis/DevSite/Projects/ComponentArchitecture/Zope3Book/skin.html 
a ressource is included without specification of type

Next question: I also want to have a template which could be accessible 
from all packages with the standard 
metal:use-macro="views/standard_macros/..." Where to place and how to 
configure that, so that is available for all packages?

Thx,

Florian





More information about the Zope3-dev mailing list