From 812b9c1285ff0a0cc059677366eb805a5a239ccf Mon Sep 17 00:00:00 2001 From: Roberto Alsina Date: Sat, 15 Apr 2023 18:59:08 -0300 Subject: [PATCH] Add linting --- notebook_nueva/Makefile | 9 +++++++-- notebook_nueva/base.py | 2 +- notebook_nueva/components/screen_pillars.py | 2 +- notebook_nueva/requirements.txt | 1 + 4 files changed, 10 insertions(+), 4 deletions(-) diff --git a/notebook_nueva/Makefile b/notebook_nueva/Makefile index 7a9ede9..b078272 100644 --- a/notebook_nueva/Makefile +++ b/notebook_nueva/Makefile @@ -1,6 +1,11 @@ STL_FILES = base.stl hinged_lid.stl simple_lid.stl tandy_lid.stl -all: $(STL_FILES) +all: $(STL_FILES) .lint %.stl: %.py dimensions.py utils.py - python $< \ No newline at end of file + python $< + +.lint: *.py + flake8 + touch .lint + diff --git a/notebook_nueva/base.py b/notebook_nueva/base.py index 00619b9..19ca435 100644 --- a/notebook_nueva/base.py +++ b/notebook_nueva/base.py @@ -1,5 +1,5 @@ import cadquery as cq -from cq_warehouse.drafting import Draft +# from cq_warehouse.drafting import Draft import components.audio_plug as audio_plug import components.battery_holder as battery_holder diff --git a/notebook_nueva/components/screen_pillars.py b/notebook_nueva/components/screen_pillars.py index 7fc8c30..11f861a 100644 --- a/notebook_nueva/components/screen_pillars.py +++ b/notebook_nueva/components/screen_pillars.py @@ -2,7 +2,7 @@ from utils import extrude_shape, punch_hole import cadquery as cq elements = None -bottom_holes = None # Not really vents FIXME +bottom_holes = None def init(positions, thickness): diff --git a/notebook_nueva/requirements.txt b/notebook_nueva/requirements.txt index e681b12..430e0cb 100644 --- a/notebook_nueva/requirements.txt +++ b/notebook_nueva/requirements.txt @@ -1,2 +1,3 @@ cadquery git+https://github.com/gumyr/cq_warehouse.git#egg=cq_warehouse +flake8