From 2216f766e5a78532500b87f1bbce512829e97a9c Mon Sep 17 00:00:00 2001 From: Arthur Moore Date: Thu, 17 Oct 2024 03:01:38 -0400 Subject: [PATCH] Move scad files not meant for end users to "src" directory --- gridfinity-rebuilt-baseplate.scad | 9 +++++---- gridfinity-rebuilt-bins.scad | 5 +++-- gridfinity-rebuilt-lite.scad | 7 +++++-- gridfinity-spiral-vase.scad | 6 ++++-- .../core/gridfinity-rebuilt-holes.scad | 2 +- .../core/gridfinity-rebuilt-utility.scad | 4 ++-- standard.scad => src/core/standard.scad | 0 {external => src/external}/threads-scad/threads.scad | 0 generic-helpers.scad => src/helpers/generic-helpers.scad | 0 tests/test_holes.py | 2 +- 10 files changed, 21 insertions(+), 14 deletions(-) rename gridfinity-rebuilt-holes.scad => src/core/gridfinity-rebuilt-holes.scad (99%) rename gridfinity-rebuilt-utility.scad => src/core/gridfinity-rebuilt-utility.scad (99%) rename standard.scad => src/core/standard.scad (100%) rename {external => src/external}/threads-scad/threads.scad (100%) rename generic-helpers.scad => src/helpers/generic-helpers.scad (100%) diff --git a/gridfinity-rebuilt-baseplate.scad b/gridfinity-rebuilt-baseplate.scad index d850272..05d82e2 100644 --- a/gridfinity-rebuilt-baseplate.scad +++ b/gridfinity-rebuilt-baseplate.scad @@ -1,7 +1,3 @@ -include -include -use - // ===== INFORMATION ===== // /* IMPORTANT: rendering will be better for analyzing the model if fast-csg is enabled. As of writing, this feature is only available in the development builds and not the official release of OpenSCAD, but it makes rendering only take a couple seconds, even for comically large bins. Enable it in Edit > Preferences > Features > fast-csg @@ -10,6 +6,11 @@ https://github.com/kennetek/gridfinity-rebuilt-openscad */ +include +use +use +use + // ===== PARAMETERS ===== // /* [Setup Parameters] */ diff --git a/gridfinity-rebuilt-bins.scad b/gridfinity-rebuilt-bins.scad index c1dc147..9ff0de0 100644 --- a/gridfinity-rebuilt-bins.scad +++ b/gridfinity-rebuilt-bins.scad @@ -1,5 +1,3 @@ -include - // ===== INFORMATION ===== // /* IMPORTANT: rendering will be better for analyzing the model if fast-csg is enabled. As of writing, this feature is only available in the development builds and not the official release of OpenSCAD, but it makes rendering only take a couple seconds, even for comically large bins. Enable it in Edit > Preferences > Features > fast-csg @@ -26,6 +24,9 @@ https://github.com/kennetek/gridfinity-rebuilt-openscad */ +use +use + // ===== PARAMETERS ===== // /* [Setup Parameters] */ diff --git a/gridfinity-rebuilt-lite.scad b/gridfinity-rebuilt-lite.scad index 43194af..543f471 100644 --- a/gridfinity-rebuilt-lite.scad +++ b/gridfinity-rebuilt-lite.scad @@ -1,5 +1,3 @@ -include - // ===== INFORMATION ===== // /* IMPORTANT: rendering will be better for analyzing the model if fast-csg is enabled. As of writing, this feature is only available in the development builds and not the official release of OpenSCAD, but it makes rendering only take a couple seconds, even for comically large bins. Enable it in Edit > Preferences > Features > fast-csg @@ -8,6 +6,11 @@ https://github.com/kennetek/gridfinity-rebuilt-openscad */ +include +use +use +use + // ===== PARAMETERS ===== // /* [Setup Parameters] */ diff --git a/gridfinity-spiral-vase.scad b/gridfinity-spiral-vase.scad index 93ac20c..b5fdd9c 100644 --- a/gridfinity-spiral-vase.scad +++ b/gridfinity-spiral-vase.scad @@ -1,5 +1,3 @@ -include - // ===== INFORMATION ===== // /* IMPORTANT: rendering will be better for analyzing the model if fast-csg is enabled. As of writing, this feature is only available in the development builds and not the official release of OpenSCAD, but it makes rendering only take a couple seconds, even for comically large bins. Enable it in Edit > Preferences > Features > fast-csg @@ -8,6 +6,10 @@ https://github.com/kennetek/gridfinity-rebuilt-openscad */ +include +use +use + // ===== PARAMETERS ===== // /* [Special Variables] */ diff --git a/gridfinity-rebuilt-holes.scad b/src/core/gridfinity-rebuilt-holes.scad similarity index 99% rename from gridfinity-rebuilt-holes.scad rename to src/core/gridfinity-rebuilt-holes.scad index 5aa3efd..7e40729 100644 --- a/gridfinity-rebuilt-holes.scad +++ b/src/core/gridfinity-rebuilt-holes.scad @@ -4,7 +4,7 @@ */ include -use +use <../helpers/generic-helpers.scad> /** * @brief Determines the number of fragments in a circle. Aka, Circle resolution. diff --git a/gridfinity-rebuilt-utility.scad b/src/core/gridfinity-rebuilt-utility.scad similarity index 99% rename from gridfinity-rebuilt-utility.scad rename to src/core/gridfinity-rebuilt-utility.scad index c87e486..9084fb3 100644 --- a/gridfinity-rebuilt-utility.scad +++ b/src/core/gridfinity-rebuilt-utility.scad @@ -5,9 +5,9 @@ */ include -use use -use +use <../helpers/generic-helpers.scad> +use <../external/threads-scad/threads.scad> // ===== User Modules ===== // diff --git a/standard.scad b/src/core/standard.scad similarity index 100% rename from standard.scad rename to src/core/standard.scad diff --git a/external/threads-scad/threads.scad b/src/external/threads-scad/threads.scad similarity index 100% rename from external/threads-scad/threads.scad rename to src/external/threads-scad/threads.scad diff --git a/generic-helpers.scad b/src/helpers/generic-helpers.scad similarity index 100% rename from generic-helpers.scad rename to src/helpers/generic-helpers.scad diff --git a/tests/test_holes.py b/tests/test_holes.py index ad55356..e153318 100644 --- a/tests/test_holes.py +++ b/tests/test_holes.py @@ -10,7 +10,7 @@ from openscad_runner import * @pytest.fixture def openscad_runner(pytestconfig) -> OpenScadRunner: - scad_path = pytestconfig.rootpath.joinpath('gridfinity-rebuilt-holes.scad') + scad_path = pytestconfig.rootpath.joinpath('src/core/gridfinity-rebuilt-holes.scad') scad_runner = OpenScadRunner(scad_path) scad_runner.image_folder_base = pytestconfig.rootpath.joinpath('images/hole_cutouts/') scad_runner.camera_arguments = CameraArguments(Vec3(0,0,0), CameraRotations.AngledTop, 50)