parkr / auto-reply

:loop: Handle GitHub webhooks and manage issues on your repositories. Used to run @jekyllbot, now at github.com/jekyll/jekyllbot
https://byparker.com/go/auto-reply
BSD 3-Clause "New" or "Revised" License
69 stars 13 forks source link

Automatically add [ci-skip] to documentation related commits #35

Closed DirtyF closed 6 years ago

DirtyF commented 6 years ago

I always forgot to add [ci-skip] to documentation commits to avoid triggering a useless CI build. 😕

Could @jekyllbot help?

Given a contributor update Jekyll's website or documentation
When the PR is submitted
Then all commits prefixed with `Docs:` do not trigger a CI check
And all modified files in the `_docs` directory do not trigger a CI check
And all PR tagged with `documentation`  do not trigger a CI check
And all PR tagged with `site`  do not trigger a CI check
ashmaroli commented 6 years ago

On thinking about this, I believe there's nothing much JekyllBot could do here. CI builds are immediately triggered by git push. So the [ci skip] attribute would only make sense if its present before the git push event.

A similar approach is already followed in practice when JekyllBot updates the History file, irrespective of the changes:

github com_jekyll_jekyll_pull_7133