From 29d11f928ad613ebaaba29607311639f6f0dbc2d Mon Sep 17 00:00:00 2001 From: Kye Date: Thu, 23 Nov 2023 19:36:34 -0800 Subject: [PATCH] no developers md -> contributing md --- CONTRIBUTING.md | 20 ++++++++++++++++++++ Developers.md | 21 --------------------- pyproject.toml | 4 ++-- 3 files changed, 22 insertions(+), 23 deletions(-) delete mode 100644 Developers.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 04f0f593..08487720 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -43,11 +43,28 @@ git push -u origin main ``` ## 🎨 Code quality +- Follow the following guide on code quality a python guide or your PR will most likely be overlooked: [CLICK HERE](https://google.github.io/styleguide/pyguide.html) ### Pre-commit tool This project utilizes the [pre-commit](https://pre-commit.com/) tool to maintain code quality and consistency. Before submitting a pull request or making any commits, it is important to run the pre-commit tool to ensure that your changes meet the project's guidelines. + +- Install pre-commit (https://pre-commit.com/) + +```bash +pip install pre-commit +``` + +- Check that it's installed + +```bash +pre-commit --version +``` + +Now when you make a git commit, the black code formatter and ruff linter will run. + + Furthermore, we have integrated a pre-commit GitHub Action into our workflow. This means that with every pull request opened, the pre-commit checks will be automatically enforced, streamlining the code review process and ensuring that all contributions adhere to our quality standards. To run the pre-commit tool, follow these steps: @@ -60,6 +77,9 @@ To run the pre-commit tool, follow these steps: 4. You can also install pre-commit as a git hook by execute `pre-commit install`. Every time you made `git commit` pre-commit run automatically for you. + + + ### Docstrings All new functions and classes in `swarms` should include docstrings. This is a prerequisite for any new functions and classes to be added to the library. diff --git a/Developers.md b/Developers.md deleted file mode 100644 index ca7fda93..00000000 --- a/Developers.md +++ /dev/null @@ -1,21 +0,0 @@ -Developers - -Install pre-commit (https://pre-commit.com/) - -```bash -pip install pre-commit -``` - -Check that it's installed - -```bash -pre-commit --versioni -``` - -This repository already has a pre-commit configuration. To install the hooks, run: - -```bash -pre-commit install -``` - -Now when you make a git commit, the black code formatter and ruff linter will run. diff --git a/pyproject.toml b/pyproject.toml index 6377e1db..1ecd02ad 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -77,11 +77,11 @@ mypy-protobuf = "^3.0.0" [tool.autopep8] -max_line_length = 120 +max_line_length = 80 ignore = "E501,W6" # or ["E501", "W6"] in-place = true recursive = true aggressive = 3 [tool.ruff] -line-length = 120 \ No newline at end of file +line-length = 80 \ No newline at end of file