How to quickstart a project with genshi?

1 view
Skip to first unread message

Italo Maia

unread,
Dec 13, 2006, 12:21:07 AM12/13/06
to TurboGears
I'm using tg1.0b2 and i runned tgsetup.py with --future, but i have no
idea how to create a project with genshi enabled. How do i do that?

ps: I runned tgsetup without --future, before running it with future,
could that be a problem?

Elvelind Grandin

unread,
Dec 13, 2006, 1:24:51 AM12/13/06
to turbo...@googlegroups.com
There is no quickstart templates using genshi yet.


--
cheers
elvelind grandin

Arnar Birgisson

unread,
Dec 13, 2006, 3:34:04 AM12/13/06
to turbo...@googlegroups.com
In the meantime, here's a skeleton for a TG project with Genshi:
http://genshi.edgewall.org/browser/trunk/examples/turbogears

Arnar

Italo Maia

unread,
Dec 13, 2006, 4:00:04 AM12/13/06
to TurboGears
And how do i download that??

Arnar Birgisson

unread,
Dec 13, 2006, 4:33:04 AM12/13/06
to turbo...@googlegroups.com
Good point.. :o)

If you have svn:
svn export http://svn.edgewall.org/repos/genshi/trunk/examples/turbogears/
genshitg

if not, but you have something like wget:
wget -r -np http://svn.edgewall.org/repos/genshi/trunk/examples/turbogears/

If you don't have either - let me know and I'll send you an archive.

Arnar

On 12/13/06, Italo Maia <italo...@gmail.com> wrote:
>

gasolin

unread,
Dec 13, 2006, 4:44:24 AM12/13/06
to TurboGears
I suggest you use the templates in tg trunk, which has the same look
and feel as in 1.0b2.

http://trac.turbogears.org/turbogears/browser/trunk/turbogears/qstemplates/quickstart/%2Bpackage%2B/templates?rev=1925

shday

unread,
Dec 13, 2006, 9:18:27 AM12/13/06
to TurboGears
I used "easy_install Genshi", as described here:

http://docs.turbogears.org/1.0/GenshiTemplating

Then in app.cfg you can change the tg.defaultview:

tg.defaultview = "genshi"

Or you can just prefix all your template references with "genshi:"

It should be quite painless. :)

Dennis Muhlestein

unread,
Dec 13, 2006, 2:44:39 PM12/13/06
to TurboGears

Except that then your genshi templates don't have support for widgets
and other turbogears defined methods. If you download the sample
mentioned before, you get a site template in genshi that makes widgets
work correctly. (at least all the ones I've used since installing
genshi)

Italo Maia

unread,
Dec 14, 2006, 5:27:25 PM12/14/06
to TurboGears
So, i should use the template from the tg docs?

Dennis Muhlestein

unread,
Dec 15, 2006, 12:58:47 PM12/15/06
to TurboGears

On Dec 14, 3:27 pm, "Italo Maia" <italo.m...@gmail.com> wrote:
> So, i should use the template from the tg docs?

I was referring to the example TG app provided by Genshi:
http://svn.edgewall.org/repos/genshi/trunk/examples/turbogears/
Specifically, the master template includes a sitetemplate.html file
that provides the appropriate code to include Widget Javascript and
Css. Of course, you can do this manually in any of your projects. I
just meant that this is what I needed to have done to my project before
I could start using Genshi throughout.

-Dennis

Reply all
Reply to author
Forward
0 new messages