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 yaml configuration #306

Open
nonowazu opened this issue Sep 27, 2022 · 0 comments
Open

generate yaml configuration #306

nonowazu opened this issue Sep 27, 2022 · 0 comments

Comments

@nonowazu
Copy link
Contributor

I'm not sure if this ends up being a hugo generation item or a scripting language with a config file, but I'm pretty sure that:

  1. the current one is horrifying to edit (at 6.8k lines long
  2. It means changes like Change the admin editor from a static affair to a dynamic one #299 require us to keep two of the same file around, (yes, I realize only ~10 lines differ between them, but it's still something to keep in sync
  3. The current method is error prone (typo in a field can break pages, for example)

I'd like to propose (perhaps) adding a python script that would take in a configuration file (json/yaml/toml – I don't care) and generate the .yml file on demand. This could be run on a developer machine to generate a functional configuration for dev yaml, and production workflow(s) could generate it as part of the "generate the website" steps. The reasons I suggest python are:

  1. It's widely available in a github action
  2. If we choose .ini or .json (and .toml as of python 3.11) for the config file, it's all standard library all the way down
  3. Doesn't require any compilation/extra steps to make work (other than installing python on a dev machine I guess?)
  4. Could be dockerized (weird to create a container just for generating a configuration file, but what a world I suggest we live in)
  5. I like python
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

No branches or pull requests

1 participant