zola init shoud prefill basic example template

Created on 3 Mar 2020  Â·  8Comments  Â·  Source: getzola/zola

During my startup with Zola i found it hard to get a good gripe with how this (or any) static site generator works. The docs are fairly complete but lack a "hand holding session" which guides you trough your first template setup.

There have been some earlier issues made (#534 , #466) but they focus on the docs side of things and what i found when i ran zola init was a bunch of empty directories. And the current docs are imo a better reference for when you have a basic setup.

So what i'd like to propose is to prepopulate the directories with a super basic template setup:

  • /sass

    • main.scss with a simple head styling setup

  • /static

    • Zola logo image

  • /content

    • index.md with some markdown examples and links to the docs

  • /templates

    • index.html with:

    • Logo from /static

    • css include from /sass

    • content block render

  • /themes

    • .keep so git won't remove this directory

During my setup i found this very useful: https://github.com/getzola/zola/issues/534#issuecomment-551065726 so we might simplify and edit this setup.

This would be a very basic example but we can incorporate some best practices too like presetting some meta tags.

I think this would help newcomers a fair bit. And maybe ask if this should be done during the init.

P.s. additionally asking if git should be initialized might also be an good idea

Most helpful comment

I think an example website to walkthrough might be helpful to solve this problem — even though it was in the documentation, it took me a while to figure out how to generate a list of all of my posts — I feel like an example site that I could poke around in would have been helpful

Sent with GitHawk

All 8 comments

Note that the docs now have a quickstart section: https://www.getzola.org/documentation/getting-started/overview/
Overview might be a bad name for it though. The issue I have with putting some files in zola init is that right now if you do zola serve you get some indications on what to do to proceed. We could have the same in a template/markdown but I am not really sure how to organise that.

The getting-started page is indeed very helpful to start.
But currently when you do zola init you'll get just a bunch of empty folders.
And even some basic setup files (like what you get when you run zola serve) would be helpful. Even if just to browse trough and not to have the getting-started page side-by-side

can we get hugo like experience for creating new posts by using cli.
like zola new --post hello.md

zola new --post hello.md is not going to happen

sorry, What can we do to make it happen.

You can probably write a Makefile for that but let's not derail the issue. This isn't about zola new

Thanks for reply

I think an example website to walkthrough might be helpful to solve this problem — even though it was in the documentation, it took me a while to figure out how to generate a list of all of my posts — I feel like an example site that I could poke around in would have been helpful

Sent with GitHawk

Was this page helpful?
0 / 5 - 0 ratings

Related issues

NuLL3rr0r picture NuLL3rr0r  Â·  6Comments

nikhiljha picture nikhiljha  Â·  5Comments

phil-opp picture phil-opp  Â·  6Comments

upsuper picture upsuper  Â·  3Comments

svenstaro picture svenstaro  Â·  5Comments