https://github.com/smithy-lang/smithy-dafny/pull/512 is implementing this in sed, but Dafny's replaceable modules feature is a much cleaner and well-supported solution. An earlier attempt to do this ran into problems, but they seem either already solved or orthogonal.
I think there may be another issue, where we need to combine "MultipleModels" with per-language replaceable modules. I expect this can be solved with Makefile magic.
https://github.com/smithy-lang/smithy-dafny/pull/512 is implementing this in sed, but Dafny's replaceable modules feature is a much cleaner and well-supported solution. An earlier attempt to do this ran into problems, but they seem either already solved or orthogonal.