godotengine / godot-website

The code for the official Godot Engine website. A static site built using Jekyll.
https://godotengine.org
MIT License
292 stars 143 forks source link

Add support for download config overrides #748

Closed YuriSizov closed 9 months ago

YuriSizov commented 10 months ago

Overrides operate on inclusive version ranges. You can see how it looks in the modified YAML file. The first match config is going to be used, so order matters. This can be important if we introduce and remove something in a number of releases inside another range.

When testing I've checked that the download block in articles is unaffected, and so are download pages. Expected changes are:

To match versions to ranges I use a simple hashing mechanism which turns version name (e.g. "4.1.3") and version flavor (e.g. "alpha17") into integer values. These are easy to compare.

Calinou commented 10 months ago

Tested locally, it works as expected:

image

Note that you need to click Show all downloads on the right for the ARM downloads to be visible (same goes for 32-bit x86, so this isn't a new issue).

PS: Is the ".NET - Standard" listing intended? I thought it was either "Standard" or ".NET", not both.

YuriSizov commented 10 months ago

Is the ".NET - Standard" listing intended? I thought it was either "Standard" or ".NET", not both.

It's an unfortunate necessity to make everything formatted properly across the website without having excessive configs.

It's just a .NET version of your normal editor build.

akien-mga commented 9 months ago

Is the ".NET - Standard" listing intended? I thought it was either "Standard" or ".NET", not both.

It's an unfortunate necessity to make everything formatted properly across the website without having excessive configs.

It's just a .NET version of your normal editor build.

This could maybe be done like "Export templates" and "Export templates - .NET"? We could also add "editor" like we do for "Web editor" so that it's clearer that users don't need to download say "Android" to get Android support.

So it would be:

Android editor - Universal APK (...)
Linux editor (x86_64)
Linux editor - .NET (x86_64)
Web editor
YuriSizov commented 9 months ago

To be clear, this .NET Standard thing is already present on the website since many months ago. It was needed to unify some variations in the naming that we have. I didn't find a better solution and considered it a fine compromise.

YuriSizov commented 9 months ago

Thanks for reviews, let's see if anything breaks 🙃