gnormal / gnorm

A database-first code generator for any language
https://gnorm.org
Other
487 stars 40 forks source link

Add useful default templates #104

Closed nhooyr closed 4 years ago

nhooyr commented 5 years ago

Would be nice to have some default templates.

nhooyr commented 5 years ago

Whoops we already do.

nhooyr commented 5 years ago

Useful default templates would be cool.

natefinch commented 5 years ago

https://github.com/gnormal/postgres-go has some example templates. I should update those with what we've been using at work. They're a lot more extensive and useful.

nhooyr commented 5 years ago

That sounds great to me. We should link to those on the site. Otherwise I think for most users, the barrier to use gnorm is high because the setup time to create templates is high and there are no examples listed so you aren't really sure what you get.

nhooyr commented 5 years ago

Would be nice to generate tests too.

Etomyutikos commented 5 years ago

Despite the absence of examples, I found the documentation to be exceptional for crafting my own templates. But, agreed, good examples can go a long way.

freb commented 5 years ago

I'm currently using xo, but I really like what I'm seeing with this project. Should I wait to kick the tires until the postgres templates are updated? Any timeline on that? Thanks for the fantastic work.

natefinch commented 5 years ago

I'll get the postgres templates updated asap. It's just a matter of copying what we use at work.

On Sat, Sep 22, 2018, 3:39 AM Jeff Stiles notifications@github.com wrote:

I'm currently using xo, but I really like what I'm seeing with this project. Should I wait to kick the tires until the postgres templates are updated? Any timeline on that? Thanks for the fantastic work.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/gnormal/gnorm/issues/104#issuecomment-423724521, or mute the thread https://github.com/notifications/unsubscribe-auth/ADCcyFaa_DdJpkUF1LM9iW5mWo_RN6_mks5udekwgaJpZM4WCdyL .

nhooyr commented 5 years ago

Very excited 🎊

natefinch commented 5 years ago

https://github.com/gnormal/postgres-go

Just updated.

natefinch commented 5 years ago

note that a PR is about to land that adds support for other template languages.... a very simple example is at https://github.com/gnormal/jinja-example

nhooyr commented 5 years ago

@natefinch the jinja repository is inaccessible for me.

natefinch commented 5 years ago

refresh, I typoed the link

natefinch commented 5 years ago

it's at https://github.com/gnormal/jinja-example

freb commented 5 years ago

@natefinch, thanks for the update!

nhooyr commented 4 years ago

Going to close as it has been a long time and I'm not sure if this is relevant anymore.