diff --git a/.flake8 b/.flake8 new file mode 100644 index 0000000..63cfd5c --- /dev/null +++ b/.flake8 @@ -0,0 +1,3 @@ +[flake8] +max-line-length = 88 +extend-ignore = E203, E501 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 0000000..3198c80 --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,34 @@ +repos: +- repo: https://github.com/pre-commit/pre-commit-hooks + rev: v4.2.0 + hooks: + - id: trailing-whitespace + - id: end-of-file-fixer + - id: mixed-line-ending + - id: check-json + - id: check-toml + - id: check-yaml + - id: check-merge-conflict + - id: debug-statements + - id: name-tests-test +- repo: local + # run all of these hooks from the Poetry versions + hooks: + - id: isort + name: isort + entry: python3 -m isort + language: system + types: [python] + require_serial: true + - id: black + name: black + entry: python3 -m black + language: system + types: [python] + require_serial: true + - id: flake8 + name: flake8 + entry: python3 -m flake8 + language: system + types: [python] + require_serial: true diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..78685fc --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,10 @@ +# Contributing + +## Technical Notes + +Please install our pre-commit scripts to ensure your code is properly formatted. + +```bash +python3 -m pip install pre-commit black flake8 isort +pre-commit install +``` diff --git a/fogros2/requirements-dev.txt b/fogros2/requirements-dev.txt new file mode 100644 index 0000000..5e5647a --- /dev/null +++ b/fogros2/requirements-dev.txt @@ -0,0 +1,3 @@ +black +flake8 +isort