Skip to content

Model ~/.metanorma/config.yml with LutaML#366

Draft
ribose-jeffreylau wants to merge 2 commits into
mainfrom
365-config
Draft

Model ~/.metanorma/config.yml with LutaML#366
ribose-jeffreylau wants to merge 2 commits into
mainfrom
365-config

Conversation

@ribose-jeffreylau

Copy link
Copy Markdown
Contributor

Metanorma PR checklist

Fixes #365

@ribose-jeffreylau ribose-jeffreylau added the enhancement New feature or request label Mar 5, 2025
@ribose-jeffreylau ribose-jeffreylau self-assigned this Mar 5, 2025

@ronaldtse ronaldtse left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ribose-jeffreylau

Copy link
Copy Markdown
Contributor Author

This actually is not as straightforward as initially thought.

Currently, the config Hash is being manipulated with .merge (in multiple places) and is then passed to Metanorma::Compile:

options = @compile_options.merge(
format: :asciidoc, output_dir: build_asset_output_directory(source),
site_generate: true
)
options[:baseassetpath] = Pathname.new(source.to_s).dirname.to_s
Metanorma::Cli::Compiler.compile(source.to_s, options)

Not sure how best to handle mutations to a LutaML model for now...

@ronaldtse

Copy link
Copy Markdown
Contributor

This thing is not supposed to be manipulated after. The merges are just used to set defaults or additional things, they can be easily changed to method setters. Now being a lutaml-model we can set those things earlier on and can also allow the user to set them in the config, which is a great feature.

Base automatically changed from 353-name to main March 7, 2025 04:42
@opoudjis

Copy link
Copy Markdown
Contributor

@ribose-jeffreylau @ronaldtse This PR has been unactioned for six months. Is it still to be fixed?

@opoudjis

Copy link
Copy Markdown
Contributor

@ribose-jeffreylau @ronaldtse Update on this please. Metanorma is being plagued by PRs sitting unactioned for months.

@opoudjis

opoudjis commented Mar 2, 2026

Copy link
Copy Markdown
Contributor

@ronaldtse @ribose-jeffreylau This has now been sitting unactioned for a full year. If I do not hear back from either of you in the next week, I will be closing this PR.

opoudjis added a commit that referenced this pull request Jul 21, 2026
…i#366)

Completes ci#365 by fixing the tag-creation gap #438 left open.

Previous shape (#438): docker-dispatch job fired `gh workflow run
build-push.yml` + build-push-windows.yml on metanorma-docker main.
build-push builds off main, which reads docker's own latest tag —
rebuilding the LAST cli version, not the newly-released one. Every
fortnight required manual `gh workflow run release-tag.yml` to
create the matching docker tag; automation did not close that loop.

This PR: docker-dispatch now fires `repository_dispatch:
[metanorma/metanorma-cli]` at metanorma-docker's release-tag.yml
(which already exposed that listener but nothing dispatched to it).
release-tag.yml parses the cli version from client_payload.ref,
updates VERSION.mak + Gemfile, creates the matching vX.Y.Z tag,
and the tag push triggers build-push + build-push-windows AT the
tag with the correct version.

After merge: next cli tag push → rake tests → tests-passed →
release-tag creates docker tag → docker images build at correct
version. Zero manual intervention across the cli → docker chain.

Closes #366 on metanorma/ci.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Model ~/.metanorma/config.yml with LutaML

3 participants