Skip to content

Commit 3df7735

Browse files
authored
Merge pull request #700 from Labelbox/jtso/readme
2 parents 86976fe + 622f8b2 commit 3df7735

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

CONTRIB.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,14 @@ following packages/modules:
2525
* Approved PRs are merged to the `develop` branch.
2626
* The `develop` branch is merged to `master` on each release.
2727

28+
## Commits
29+
30+
Before making a commit, to automatically adhere to our formatting standards,
31+
install and activate [pre-commit](https://pre-commit.com/)
32+
33+
After the above, running `git commit ...` will attempt to fix formatting. If
34+
there was formatted needed, you will need to re-add and re-commit before pushing.
35+
2836
## Testing
2937

3038
Currently, the SDK functionality is tested using integration tests. These tests
@@ -36,7 +44,8 @@ To execute tests you will need to provide an API key for the server you're using
3644
for testing (staging by default) in the `LABELBOX_TEST_API_KEY` environment
3745
variable. For more info see [Labelbox API key docs](https://labelbox.helpdocs.io/docs/api/getting-started).
3846

39-
To pass tests, code must be formatted using the following command:
47+
To pass tests, code must be formatted. If pre-commit was not installed,
48+
you will need to use the following command:
4049

4150
```shell
4251
yapf tests labelbox -i --verbose --recursive --parallel --style "google"
@@ -54,4 +63,4 @@ Each release should follow the following steps:
5463
6. This will kick off a Github Actions workflow that will:
5564
- Build the library in the [standard way](https://packaging.python.org/tutorials/packaging-projects/#generating-distribution-archives)
5665
- Upload the distribution archives in the [standard way](https://packaging.python.org/tutorials/packaging-projects/#uploading-the-distribution-archives)
57-
with credentials for the `labelbox` PyPI user.
66+
with credentials for the `labelbox` PyPI user.

0 commit comments

Comments
 (0)