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

Generate and publish shotover website #1853

Merged
merged 1 commit into from
Dec 4, 2024
Merged

Conversation

rukai
Copy link
Member

@rukai rukai commented Nov 29, 2024

This PR demonstrates the full website via github pages implementation.
It is temporarily hosted here: https://shotovertest.rukai.xyz/ (running from my github fork of the repo)
And can be compared to the current website at https://shotover.io/

Once the website is deployed we need to follow the steps at https://docs.github.com/en/pages/configuring-a-custom-domain-for-your-github-pages-site/managing-a-custom-domain-for-your-github-pages-site for github.com/shotover/shotover-proxy with shotover.io domain.

The current website implementation is hosted at https://github.com/shotover/shotover-website , it is implemented with an early alpha release of vuepress. I previously attempted to upgrade to a modern version of vuepress but gave up because the upgrade changed all kinds of css/html leaving the formatting broken.

This PR implements the website via a new website crate in the cargo workspace.
Running the website crate generates the website at website/root, by following these steps:

  • Generate the landing page index.html
    • The landing page is generated from a manually stripped down version of the original website, this avoids the npm dependency and makes the site faster to load.
  • Generate the documentation index docs/index.html
    • Links are generated for all the documentation generated in the following steps (except main branch docs which are intentionally hidden)
    • Shares css and base html template with the landing page.
  • Generate main docs docs/main
    • Run mdbook on the current state of the repo
      • mdbook was what we originally used for documentation before the shotover website rewrite. The rewrite never quite had proper compatibility with the original mdbook, so swapping back to mdbook will improve compatibility.
  • Generate docs for every released version docs/x.y.z
    • Clone another shotover repo from the latest github.com/shotover/shotover-proxy, run git tag to find the latest version of breaking releases and then generate mdbook docs from the sub repo after checking out each tag.
  • Generate docs for the latest released version docs/latest
    • Take the latest release from the step and regenerate it at docs/latest

Intentional changes to the landing page of the original website:

  • The navbar at the top has underlined links, makes it easier to tell they are navigation.
  • The image of the shotover river at the very bottom is left out, I'm pretty sure we dont actually have the rights to use this image.
  • I removed the light/dark mode button, instead light/dark mode is determined from the users system preferences for ligh/dark mode.
    • I see no value in providing the option, just use what the user prefers by default.
  • I removed the stock images from "What problems does Shotover solve?" section, they are probably from the original template and dont really have any meaning here.

Reviewing

I will split the PR up into 2 separate PRs for easier review:

Copy link

codspeed-hq bot commented Nov 29, 2024

CodSpeed Performance Report

Merging #1853 will not alter performance

Comparing rukai:publish-pages (e7d71e7) with main (21a0ff7)

Summary

✅ 38 untouched benchmarks

@rukai rukai force-pushed the publish-pages branch 9 times, most recently from f434c4d to 527ef05 Compare December 3, 2024 00:53
@rukai rukai changed the title [WIP] publish docs to /docs/main publish docs to /docs/main Dec 3, 2024
@rukai rukai changed the title publish docs to /docs/main Generate and publish shotover website Dec 3, 2024
@rukai rukai force-pushed the publish-pages branch 4 times, most recently from 70a9f90 to 0df25f7 Compare December 3, 2024 02:46
@rukai rukai mentioned this pull request Dec 3, 2024
@rukai rukai force-pushed the publish-pages branch 4 times, most recently from cc26eb5 to 6a4d26e Compare December 3, 2024 22:03
@rukai rukai marked this pull request as ready for review December 3, 2024 22:34
@justinweng-instaclustr
Copy link
Collaborator

Overall LGTM.
Just a minor comment. The original doc page has this Shotover logo at the top right corner that allows you to go back to the home page while the new doc page doesn't provide the way to navigate back anymore. Is this intended?
Screenshot 2024-12-04 at 10 54 54 AM
image

@rukai
Copy link
Member Author

rukai commented Dec 4, 2024

It is currently intended, mdbook does provide a way to add some custom html, and I would like to use that functionality to reintroduce a link back to the landing page at sometime, but its not a priority right now.

@rukai rukai merged commit c1c50b9 into shotover:main Dec 4, 2024
40 checks passed
@rukai rukai mentioned this pull request Dec 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants