When importing a site to local, any other files and folders than the default (app, conf, logs) get deleted by local. I use git for version control. For portability and compatibility purposes, I like to include the whole site folder in my git repos. This allows for easier testing and follow-ups, as well as a simpler way of using more than one device with local, as once a site is set-up on both devices, I can simply sync the site against a git remote and seamlessly keep coding interchangeably on them both.
However, as local currently is built, the setting-up procedure of accomplishing this, is a major pain in the ass. And this all comes down to two reasons:
- Local requires a zip-file to import a site.
- When importing a site-zip, any other files in the site root folder is stripped.
First of all, I really don’t understand why an import needs to be zipped at all, especially since the zip can’t even be compressed to work. Why not just allow a regular directory to be selected, and check that the contents are a valid local site and add the directory and site to the local database? I saw that another user created a thread about this some years ago, under the support tag ( Import site from folder / Store local-site.json, locally ). Apparently no one answered this at all or cared to explain this design choice to an obviously dedicated user. I find this behavior very odd.
Second, why is there even a stripping function within the import module of local? This makes it seem like flywheel is actively trying to make life difficult for anyone who wants to include Local in any kind of pipeline and/or devops. This would probably be an acceptable business decision, if Flywheel actually offered a solution themselves. However, flywheel does not offer any kind of version control products that can replace git in a development environment. So as it is you’re actually just messing with your users, making life sour for them, with no business upside whatsoever for yourselves. Blocking the use of other files in the site root directory, does not drive your users closer to any other/premium product of yours. In fact, these kind of stupid design choices actually drives users further away from you as a company, as least that is the case for me.
Judging by your (lack of) response to the years-old thread, you have no intention of fixing the root issue (allowing imports of directories, instead of zip files). But can you not at least remove the stripping function from the site-import module? This would still significantly ease the use of several devices, by allowing for git pull from origin on the second device, manual packaging of the whole repo to a zip file, and then import the site to Local, run the site, and keep working.
Or, if you don’t want to do any of it, at least please explain yourselves, and suggest which premium product of yours that solves this issue.