flattenthecurve / guide

https://www.flattenthecurve.com
Creative Commons Attribution 4.0 International
38 stars 33 forks source link

Resource pre commit checks #364

Closed rousik closed 4 years ago

rousik commented 4 years ago

add pre-commit checks that will disallow manual modifications to _resources files and point people to the form. Unfortunately this will still need to be set-up by collaborators by installing pre-submit and activating on their local forks/clones by running this sequence:

pip install pre-commit
pre-commit install

I'm also working on a workflow that would send people to the form when they send PRs modifying _resources/ which might catch those that may not be caught by the pre-commit check.

It seems to me that pre-commit may be used for other Q&A tasks (e.g. limited markdown linting and such) so we might want to think if we would like to use them by default and create "set up your repo" instructions for collaborators that will ensure that pre-commit hooks are installed and used across the board.

rousik commented 4 years ago

This is related to issue #361

github-actions[bot] commented 4 years ago

This pull request is being automatically deployed with now-deployment

Built with commit abea8bd7557192e06861299270d31f51bcd853fc

✅ Preview: https://guide-preview-4wo1i89rm.now.sh

siwei-wang commented 4 years ago

My two cents: maybe we should also include a link to the google form in the enhancement? I do not git clone a local copy. I only add content by markdowns (now using the awesome form!). So it would be helpful to have both possibilities by hand when ppl like me are adding resources.

rousik commented 4 years ago

What do you mean when you say "add the google form in the enhancement"?

siwei-wang commented 4 years ago

I just meant if we may remind ppl to use it (related to #361 ).

rousik commented 4 years ago

Yup. I'm thinking that 1. pre-commit checks for those that have cloned the repo, 2. warnings on PRs that are opened, 3. README file in the _resources and possibly also 4. highlight this in the general contribution instructions for newcomers and 5. remind people on Slack that this is how things should be done.

siwei-wang commented 4 years ago

I concur! Thorough steps!