Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting started example does not properly deploy to github pages #1786

Closed
psarka opened this issue Mar 2, 2022 · 3 comments · Fixed by #1811
Closed

Getting started example does not properly deploy to github pages #1786

psarka opened this issue Mar 2, 2022 · 3 comments · Fixed by #1811

Comments

@psarka
Copy link

psarka commented Mar 2, 2022

Documentation issue

Summary

If one follows the getting started example, the resulting page does not deploy to github pages - the link on the index.html points to
http://username.github.io/blog rather than to http://username.github.io/repo/blog, even though the base_url is configured to the http://username.github.io/repo/.

Check out the repro:

https://github.com/psarka/zola-repro-1
https://psarka.github.io/zola-repro-1/

Proposed solution

Probably <p>Click <a href="/blog/">here</a> to see my posts.</p> at the end of https://www.getzola.org/documentation/getting-started/overview/ should be replaced by something base_url aware.

@Keats
Copy link
Collaborator

Keats commented Mar 3, 2022

Yes, it shouldn't hardcode urls

@milkspace
Copy link

Yes, it shouldn't hardcode urls

I solve this problem so:

<p>Click <a href="{{ config.base_url }}/blog/">here</a> to see my posts.</p>

@brleinad
Copy link
Contributor

Thanks @milkspace! I just opened #1811 with your solution.
I tested it out in a fork of psarka's repo.

Keats pushed a commit that referenced this issue Mar 29, 2022
* docs: fix overview example link

* docs: use get_url to track section

* docs: ignore get_url in example
mattico pushed a commit to mattico/zola that referenced this issue May 23, 2022
* docs: fix overview example link

* docs: use get_url to track section

* docs: ignore get_url in example
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants