I have a workflow that imports a SoT and generates a summary of the changes using
metadata.squash_notes(). Often times, these messages can include references like "#34", which left unchecked, would point to issues/PRs within my repository (and not the source of truth, like it should) on most platforms (e.g. GitHub).
To address this, I'd like to change "#34" to "foo/bar#34" within the squashed notes, which would change the reference that is linked on platforms like GitHub to the appropriate issue/PR within the appropriate user/org repository. To accomplish this, I have a pretty simple transformation:
metadata.map_references(
before = "#${reference}",
after = "foo/bar#${reference}",
regex_groups = {
"before_ref": "[0-9]+",
"after_ref": "[0-9]+",
},
)
This transformation does not seem to work in conjunction with metadata.squash_notes(), regardless of the transformation ordering. Is there something I am missing that would help me accomplish my goal?