Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add pre-commit hooks #273

Merged
merged 3 commits into from
Oct 11, 2023

Conversation

isaac-chung
Copy link
Contributor

@isaac-chung isaac-chung commented Oct 9, 2023

  • add black as pre-commit hook
  • To run
    • First install pre-commit: pip install pre-commit (or on mac brew install pre-commit)
    • check version with pre-commit --version
    • in the root of this repo, run pre-commit install
    • Then every time we run git commit, the checks are run. If the files are reformatted, git add and git commit again

Note that I've left out the rest of the hooks from here as they are not present in the GH checks.

@isaac-chung
Copy link
Contributor Author

@anas-awadalla Here we go 👍

@anas-awadalla
Copy link
Collaborator

This is very cool. Can you add the instructions on this in the readme? Under a development sub-header in the installations sections.

@anas-awadalla anas-awadalla self-requested a review October 9, 2023 20:50
@isaac-chung
Copy link
Contributor Author

For sure.

@anas-awadalla anas-awadalla merged commit 655f693 into mlfoundations:main Oct 11, 2023
1 check passed
@isaac-chung isaac-chung deleted the add-pre-commit-hooks branch October 11, 2023 07:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants