Start using pre-commit ci app
See original GitHub issueDescription
Astropy should consider using the pre-commit ci app: https://github.com/apps/pre-commit-ci, instead of its current Code style checks
github action for PRs.
Additional context
This will provide several benefits including:
- Automatic fixing of code style issues (current action uses pre-commit to enforce code style). Which should help ease the burden of code style issues on contributors. Note that this is a feature we can choose to disable globally, but might make user contributions easier since contributors would not need to install
pre-commit
,isort
,black
, etc if they don’t want to and can just pull fixed PRs from GH. - Automated PRs to update our pre-commit configuration.
See https://pre-commit.ci for details on the setup options.
See dev discussion for more details.
Blocked by
Issue Analytics
- State:
- Created a year ago
- Comments:5 (5 by maintainers)
Top Results From Across the Web
pre-commit
We built pre-commit to solve our hook issues. It is a multi-language package manager for pre-commit hooks. You specify a list of hooks...
Read more >Continuous Integration • precommit - Lorenz Walthert's
Setting up CI. When initializing pre-commit in your repo with precommit::use_precommit() , you can specify the Continuous integration provider with ci ...
Read more >Running pre-commit hooks as GitHub Actions
To run `pre-commit` as part of git workflow, use `pre-commit install `. All changes made by hooks: diff --git a /terraform/main .tf ...
Read more >pre-commit.ci
pre-commit.ci both enforces that these issues are discovered (which is opt-in for each developer's workflow via pre-commit) but also fixes the issues ...
Read more >How to use pre-commit to automatically correct commits and ...
Enabling pre-commit auto-fixes in GitLab · Create a project access token and create a CI/CD variable PRE_COMMIT_ACCESS_TOKEN with the token as a ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
At the 2022-08-11 infrastructure tag-up, we revisited https://github.com/astropy/astropy/issues/13320#issuecomment-1171488051 and discussed how to get past Step 3 that seemed stuck.
Path forward now: @WilliamJamieson will open a PR in this repo proposing the precommit config and updating relevant dev docs on how it should be used. But no precommit bot will be enabled yet on this repo until after that PR is merged.
At the 2022-06-30 infrastructure tag-up, here is the path forward agreed upon between @WilliamJamieson , @saimn , and myself:
asdf-astropy
repository with the following settings:asdf-astropy
only.asdf-astropy
and tweak the config to satisfaction.astropy
repository.Feel free to correct me if I got anything wrong.