IDEMSInternational / open-app-builder

PLH App Frontend
GNU General Public License v3.0
5 stars 24 forks source link

feat: env-replace workspace #2251

Closed chrismclarke closed 3 months ago

chrismclarke commented 3 months ago

PR Checklist

Description

Dev Notes

Whilst drafting a PR to populate android and ios template files I realised the code was quickly becoming unmanageable as there are various combinations of files to convert at different times with variables read from multiple places (e.g. Android config has about 5 file replacements but some need to leave templated strings in whilst others need to replace).

To reduce complexity I've moved the core replacement utility into its own workspace, and will make a follow-up pr to call specific methods from it as required.

The utility is designed to support various folder and filename search and exclusion patterns, as well as variable names to include/exclude. See full list of configuration variables included and test cases for more details.

Rough next steps would be

Review Notes

Test suite can be run via

yarn workspace @idemsInternational/env-replace test

Git Issues

Closes #

Screenshots/Videos

If useful, provide screenshot or capture to highlight main changes