matrix-org / matrix-appservice-slack

A Matrix <--> Slack bridge
Apache License 2.0
275 stars 72 forks source link

Refactoring substitutions #517

Open Cadair opened 4 years ago

Cadair commented 4 years ago

The bridge transforms messages in both directions to account for differences in the two platforms.

Currently these substitutions are largely in our substitutions.ts file however the code to translate slack mentions and rooms to matrix isn't in the substitutions file although it should be.

Since the last time the substitutions code has been refactored a specialist slack <> matrix library has been developed: https://github.com/Sorunome/matrix-slack-parser this issue is to track the migration of this bridge to using that library for all the translations.

This requires implementing all the callbacks that the library requires and then rewriting substitutions to use the parser library.

This issue could address all the issues labelled substitutions this includes #461 #400 #370 #357 #342 #327 #318 #315

Cadair commented 4 years ago

A stale attempt at this migration is here: #376