Git & Composer Installation Challenges

I am installing Matomo via Composer, and I’ve run into some interesting challenges. From what I can tell, key files are both supplied by composer, and are also expected to be writable by the app. This seems like an architectural issue that should be resolved. Either a file provided by the repo is the one source of truth, and should not be writable, or it is a dynamic file that should be created and modified by the app.

The matomo.js file is a good example to look at. The file is deployed as part of the source code, and is replaced when the codebase is updated (regardless of whether ftp, git, or composer are used to update the code). The problem is that if a plugin or core has updated the matomo.js file, those updates are overwritten by the new code, and are not immediately updated, following the code deploy. This holds true for all files that are deployed as part of the codebase, and need to be configured as writable.

I’m new to Matomo, so if my understanding of how the system is designed to operate, please point me in the right direction. Otherwise, I’d love to open up a discussion about using the files in the codebase as a base upon which new, dynamic files are created.