mirror of
https://github.com/hwchase17/langchain.git
synced 2025-07-01 19:03:25 +00:00
update contributing (#12532)
This commit is contained in:
parent
0b4b9e61fc
commit
d31d705407
18
.github/CONTRIBUTING.md
vendored
18
.github/CONTRIBUTING.md
vendored
@ -136,12 +136,19 @@ Run these locally before submitting a PR; the CI system will check also.
|
|||||||
|
|
||||||
Formatting for this project is done via a combination of [Black](https://black.readthedocs.io/en/stable/) and [ruff](https://docs.astral.sh/ruff/rules/).
|
Formatting for this project is done via a combination of [Black](https://black.readthedocs.io/en/stable/) and [ruff](https://docs.astral.sh/ruff/rules/).
|
||||||
|
|
||||||
To run formatting for this project:
|
To run formatting for docs, cookbook and templates:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
make format
|
make format
|
||||||
```
|
```
|
||||||
|
|
||||||
|
To run formatting for a library, run the same command from the relevant library directory:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
cd libs/{LIBRARY}
|
||||||
|
make format
|
||||||
|
```
|
||||||
|
|
||||||
Additionally, you can run the formatter only on the files that have been modified in your current branch as compared to the master branch using the format_diff command:
|
Additionally, you can run the formatter only on the files that have been modified in your current branch as compared to the master branch using the format_diff command:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
@ -154,12 +161,19 @@ This is especially useful when you have made changes to a subset of the project
|
|||||||
|
|
||||||
Linting for this project is done via a combination of [Black](https://black.readthedocs.io/en/stable/), [ruff](https://docs.astral.sh/ruff/rules/), and [mypy](http://mypy-lang.org/).
|
Linting for this project is done via a combination of [Black](https://black.readthedocs.io/en/stable/), [ruff](https://docs.astral.sh/ruff/rules/), and [mypy](http://mypy-lang.org/).
|
||||||
|
|
||||||
To run linting for this project:
|
To run linting for docs, cookbook and templates:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
make lint
|
make lint
|
||||||
```
|
```
|
||||||
|
|
||||||
|
To run linting for a library, run the same command from the relevant library directory:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
cd libs/{LIBRARY}
|
||||||
|
make lint
|
||||||
|
```
|
||||||
|
|
||||||
In addition, you can run the linter only on the files that have been modified in your current branch as compared to the master branch using the lint_diff command:
|
In addition, you can run the linter only on the files that have been modified in your current branch as compared to the master branch using the lint_diff command:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
|
Loading…
Reference in New Issue
Block a user