Did you ever think, "Hey, I should be able to use Composer to move arbitrary files around in my codebase. I wonder why they didn't put that into Composer? Now I have to write a bash script..."?
Well guess what. You don't have to write that bash script.
You can configure Composer to manage files within your codebase. We'll use the Drupal Composer Scaffold plugin to do it. The obvious advantage here (other than not needing a bash script) is that the configuration is stored within
composer.json, and thus, also your version control.