From 3db791642a2a2d918e81e6282492efdc535a7220 Mon Sep 17 00:00:00 2001
From: David Hendriks <davidhendriks93@gmail.com>
Date: Wed, 5 Oct 2022 15:57:12 +0100
Subject: [PATCH] working on cleaning the code

---
 .pre-commit-config.yaml | 9 +++++++--
 pyproject.toml          | 7 +++++++
 2 files changed, 14 insertions(+), 2 deletions(-)

diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml
index bb8a35f50..8be6a05db 100644
--- a/.pre-commit-config.yaml
+++ b/.pre-commit-config.yaml
@@ -3,14 +3,14 @@
 # See https://pre-commit.com/hooks.html for more hooks
 repos:
 -   repo: https://github.com/pre-commit/pre-commit-hooks
-    rev: v3.2.0
+    rev: v4.3.0
     hooks:
     -   id: trailing-whitespace
     -   id: end-of-file-fixer
     -   id: check-yaml
     -   id: check-added-large-files
 -   repo: https://github.com/psf/black
-    rev: stable
+    rev: 22.8.0
     hooks:
     - id: black
       language_version: python3.9
@@ -20,3 +20,8 @@ repos:
                       grav_waves/run_population_scripts/run_PPISN_population.py|
                       grav_waves/run_population_scripts/run_PPISN_population_new.py|
                   )$
+-   repo: https://github.com/pycqa/flake8
+    rev: 5.0.4
+    hooks:
+    -   id: flake8
+        args: ['--ignore=E129,E2,E501']
diff --git a/pyproject.toml b/pyproject.toml
index 2510c4857..dbcec3275 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -16,6 +16,13 @@ extend-exclude = '''
 )
 '''
 
+[tool.flake8]
+max-line-length = 89
+max-complexity = 18
+select = B,C,E,F,W,T4,B9
+
+
+
 [tool.coverage]
 #omit =
 #    test_*.py
-- 
GitLab