On Mon, Oct 20, 2008 at 4:38 PM, Christopher Arndt <[EMAIL PROTECTED]>wrote:

>
> Jorge Vargas schrieb:
> > that is awesome. In fact it's less obscure than how websetup.py works.
> > I think most of it should go inside TG, and we should write docs on
> > how to modify it, for that part I think the best will be to provide a
> > callback by means of a callable to add more stuff to the default
> > initialization.
> >
> > So everything goes in commands except create_default_user which will
> > go in quickstart and after it something of the likes of.
>
> Which file do you mean by "quickstart"?


not sure where exactly, maybe at
http://svn.turbogears.org/branches/1.1/turbogears/qstemplates/quickstart/+package+/

although
http://svn.turbogears.org/branches/1.1/turbogears/qstemplates/quickstart/+package+/model.py_tmplseems
more proper.

if tg1.1 where to use a model package, I'll say model/websetup.py (to keep
the name familiar) although +package+/websetup.py is the place where it is
in tg2/pylons.

Do you mean that we should add a new module "commands" to the TG core?
>

it's already there
http://svn.turbogears.org/branches/1.1/turbogears/command/
is there the bits of tg-admin are implemented.


> Do you mean that the bootstrap functions should already be executed at
> the end of the "tg-admin quickstart" command?
>

no, I think it should be a separate tg-admin command. But the parts that are
supposed to be edited (default user/groups/etc.) should be part of the
quickstart template.

>
> > #provide boostrap functions with default data to be inserted into the
> database,
> > #each of this should create an instance and take care of saving it
> > tg.commands.bootstrap.add(create_default_user)
>
> > then of course bootstrap will store that in a list and execute them
> > after create_tables.
>
> To be consistent with turbogears.view.variable_providers and
> turbogears.startup.call_on_startup these should be module-globals lists,
> to which the user can append with:
>
> turbogears.commands.bootstrap_commands.append(some_callable)


Good idea, we should be consistent.

>
>
>
> Chris
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears Trunk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/turbogears-trunk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to