Skip to content

templating#508

Merged
gmanchon merged 3 commits into
masterfrom
build-templating
Jun 2, 2026
Merged

templating#508
gmanchon merged 3 commits into
masterfrom
build-templating

Conversation

@gmanchon

@gmanchon gmanchon commented Jun 2, 2026

Copy link
Copy Markdown
Collaborator

adds liquid templating

replaces partials substituted constants <PYTHON_VERSION> with variables {{ PYTHON_VERSION }}

replaces partials delimiter-structured blocks :

$MAC_START
  ...
$MAC_END
$WINDOWS_START
  ...
$WINDOWS_END
$LINUX_START
  ...
$LINUX_END

with conditionals :

{% if os == "macos" %}
  ...
{% elsif os == "windows" %}
  ...
{% elsif os == "linux" %}
  ...
{% endif %}

no diffs in generated localised build files appart from blank lines

specific repo diffs

replicates lewagon/data-setup#361

@gmanchon gmanchon merged commit fcb689f into master Jun 2, 2026
@gmanchon gmanchon deleted the build-templating branch June 2, 2026 16:04
@gmanchon

gmanchon commented Jun 2, 2026

Copy link
Copy Markdown
Collaborator Author

Hello @ajdubovoy 👋

I updated the build gha to support liquid templating in order to simplify the edition of the _partials instructions

The main differences in the code structure are :

  • the variables available to all partials, as {{ RUBY_SETUP_VERSION }}, are stored in constants/constants.yml
  • the formulas are now stored in builds in yaml format, for example builds/LINUX.yml
  • it will soon be possible to parametrise a partial in order to adapt its content to the setup it is called from

No changes are made to the existing instructions

The code is a bit overkill for this repo since the setup only uses local partials, but this way the gha is coherent with the ones of the DS, DA and DE setups

@gmanchon gmanchon requested a review from krokrob June 2, 2026 16:06
@ajdubovoy

Copy link
Copy Markdown
Contributor

Thanks for the update!

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.

2 participants