codeforamerica / chime

A city-focused content management system
http://chimecms.org/
BSD 3-Clause "New" or "Revised" License
35 stars 12 forks source link

build jekyll site for preview only when necessary #524

Open tmaybe opened 8 years ago

tmaybe commented 8 years ago

Right now, previewing a single page rebuilds the entire site 8 times, once for the page itself, and once for each local CSS file, font, and image that's embedded in the page. We should put in a check (based on a repo's commit sha?) to only rebuild the preview when something's changed.

wpietri commented 8 years ago

Could we just trigger a preview when somebody clicks on the preview button? Or would that miss some corner case?

tmaybe commented 8 years ago

Might want to manually go to a preview page via altering a URL...or reload an open preview page to see the latest changes. I do both of these things.

migurski commented 8 years ago

In Jekit, we use a short timeout of 10 seconds to prevent rebuilds.