10up/wpsnapshots

Exclude build files

tlovett1 opened this issue · 2 comments

node_modules, bower_components, and vendor are currently being included in snapshots. These files really slow things down.

Bumping this. Noticed when I installed a relatively small snapshot (20MB) with a simple theme and simple plugins it took 20 minutes to install the snapshot, which is way too long, especially if we want to use snapshots in a CI pipeline for WPAcceptance. Definitely seems like node_modules and vendor folders are slowing things down If I have time I'll take a look and see if I can make an update here.

@tlovett1 Logic for ignoring build folders included in #89
The only thing that is different from the original request is I didn't exclude vendor folders by default. The reason for which is many times the vendor folders are required for websites to function, so people would need to track down all the folders with composer.json files and run composer install before they can run the site (think of plugins like Yoast that have very robust vendor folders). We can include it so it only excludes the topmost vendor folder, but again, the engineer would need to run composer install before using the site. I'd recommend we look into that separately, as those PHP files usually aren't as large as node_modules.