From ae01d00243402ed78201446f7f871cfb5fe2bc80 Mon Sep 17 00:00:00 2001 From: per1234 Date: Tue, 27 Nov 2018 22:04:24 -0800 Subject: [PATCH] Move sketches to appropriately named folders The Arduino IDE requires that a sketch be located in a folder of the same name. When opening a file that does not meet this sketch/folder name matching requirement the Arduino IDE presents a dialog: The file "SKETCHNAME.ino" needs to be inside a sketch folder named "SKETCHNAME". Create this folder, move the file, and continue? In the case of a sketch with a single source file, if you click "OK", the Arduino IDE will take the correct action, but this is an unnecessary extra step, which will cause confusion for beginners. The problem is more serious with a sketch that has multiple source files, such as Episode 6 - LED matrix. After clicking "OK" the Arduino IDE currently moves only the file SKETCHNAME.ino to the new folder, leaving behind the other source files. This causes compilation of the sketch to fail: realMatrix:17:21: error: ledData.h: No such file or directory Sketch folder name mismatch causes import of the sketches to the Arduino Web Editor via the downloaded .zip file of this repository fails: This .Zip file does not contain a sketch, check the file and try again. The sketches with single source file may be imported individually after unzipping the file, but this will leave behind the Fritzing and readme files. In the case of a multiple source file sketch such as Episode 6 - LED matrix, ledData.h is not imported along with realMatrix.ino, resulting in the same error as in the Arduino IDE. --- .../{ => hackyourplant}/episode1_fritzing.png | Bin .../{ => hackyourplant}/hackyourplant.ino | 0 .../{ => hackyourplant}/readme.md | 0 .../{ => phototransistor}/episode2_fritzing.png | Bin .../{ => phototransistor}/phototransistor.ino | 0 .../{ => retroController}/episode3_fritzing.png | Bin .../{ => retroController}/readme.md | 0 .../{ => retroController}/retroController.ino | 0 .../{ => MKR1010_config}/MKR1010_config.ino | 0 .../{ => MKR1010_config}/episode4_fritzing.png | Bin .../{ => realMatrix}/episode6_fritzing.png | Bin .../{ => realMatrix}/ledData.h | 0 .../{ => realMatrix}/readme.md | 0 .../{ => realMatrix}/realMatrix.ino | 0 14 files changed, 0 insertions(+), 0 deletions(-) rename Season 2/Episode 1 - Hack your plant/{ => hackyourplant}/episode1_fritzing.png (100%) rename Season 2/Episode 1 - Hack your plant/{ => hackyourplant}/hackyourplant.ino (100%) rename Season 2/Episode 1 - Hack your plant/{ => hackyourplant}/readme.md (100%) rename Season 2/Episode 2 - Tinker with RGB/{ => phototransistor}/episode2_fritzing.png (100%) rename Season 2/Episode 2 - Tinker with RGB/{ => phototransistor}/phototransistor.ino (100%) rename Season 2/Episode 3 - Retro game control/{ => retroController}/episode3_fritzing.png (100%) rename Season 2/Episode 3 - Retro game control/{ => retroController}/readme.md (100%) rename Season 2/Episode 3 - Retro game control/{ => retroController}/retroController.ino (100%) rename Season 2/Episode 4 - MKR1010 WiFi setup/{ => MKR1010_config}/MKR1010_config.ino (100%) rename Season 2/Episode 4 - MKR1010 WiFi setup/{ => MKR1010_config}/episode4_fritzing.png (100%) rename Season 2/Episode 6 - LED matrix/{ => realMatrix}/episode6_fritzing.png (100%) rename Season 2/Episode 6 - LED matrix/{ => realMatrix}/ledData.h (100%) rename Season 2/Episode 6 - LED matrix/{ => realMatrix}/readme.md (100%) rename Season 2/Episode 6 - LED matrix/{ => realMatrix}/realMatrix.ino (100%) diff --git a/Season 2/Episode 1 - Hack your plant/episode1_fritzing.png b/Season 2/Episode 1 - Hack your plant/hackyourplant/episode1_fritzing.png similarity index 100% rename from Season 2/Episode 1 - Hack your plant/episode1_fritzing.png rename to Season 2/Episode 1 - Hack your plant/hackyourplant/episode1_fritzing.png diff --git a/Season 2/Episode 1 - Hack your plant/hackyourplant.ino b/Season 2/Episode 1 - Hack your plant/hackyourplant/hackyourplant.ino similarity index 100% rename from Season 2/Episode 1 - Hack your plant/hackyourplant.ino rename to Season 2/Episode 1 - Hack your plant/hackyourplant/hackyourplant.ino diff --git a/Season 2/Episode 1 - Hack your plant/readme.md b/Season 2/Episode 1 - Hack your plant/hackyourplant/readme.md similarity index 100% rename from Season 2/Episode 1 - Hack your plant/readme.md rename to Season 2/Episode 1 - Hack your plant/hackyourplant/readme.md diff --git a/Season 2/Episode 2 - Tinker with RGB/episode2_fritzing.png b/Season 2/Episode 2 - Tinker with RGB/phototransistor/episode2_fritzing.png similarity index 100% rename from Season 2/Episode 2 - Tinker with RGB/episode2_fritzing.png rename to Season 2/Episode 2 - Tinker with RGB/phototransistor/episode2_fritzing.png diff --git a/Season 2/Episode 2 - Tinker with RGB/phototransistor.ino b/Season 2/Episode 2 - Tinker with RGB/phototransistor/phototransistor.ino similarity index 100% rename from Season 2/Episode 2 - Tinker with RGB/phototransistor.ino rename to Season 2/Episode 2 - Tinker with RGB/phototransistor/phototransistor.ino diff --git a/Season 2/Episode 3 - Retro game control/episode3_fritzing.png b/Season 2/Episode 3 - Retro game control/retroController/episode3_fritzing.png similarity index 100% rename from Season 2/Episode 3 - Retro game control/episode3_fritzing.png rename to Season 2/Episode 3 - Retro game control/retroController/episode3_fritzing.png diff --git a/Season 2/Episode 3 - Retro game control/readme.md b/Season 2/Episode 3 - Retro game control/retroController/readme.md similarity index 100% rename from Season 2/Episode 3 - Retro game control/readme.md rename to Season 2/Episode 3 - Retro game control/retroController/readme.md diff --git a/Season 2/Episode 3 - Retro game control/retroController.ino b/Season 2/Episode 3 - Retro game control/retroController/retroController.ino similarity index 100% rename from Season 2/Episode 3 - Retro game control/retroController.ino rename to Season 2/Episode 3 - Retro game control/retroController/retroController.ino diff --git a/Season 2/Episode 4 - MKR1010 WiFi setup/MKR1010_config.ino b/Season 2/Episode 4 - MKR1010 WiFi setup/MKR1010_config/MKR1010_config.ino similarity index 100% rename from Season 2/Episode 4 - MKR1010 WiFi setup/MKR1010_config.ino rename to Season 2/Episode 4 - MKR1010 WiFi setup/MKR1010_config/MKR1010_config.ino diff --git a/Season 2/Episode 4 - MKR1010 WiFi setup/episode4_fritzing.png b/Season 2/Episode 4 - MKR1010 WiFi setup/MKR1010_config/episode4_fritzing.png similarity index 100% rename from Season 2/Episode 4 - MKR1010 WiFi setup/episode4_fritzing.png rename to Season 2/Episode 4 - MKR1010 WiFi setup/MKR1010_config/episode4_fritzing.png diff --git a/Season 2/Episode 6 - LED matrix/episode6_fritzing.png b/Season 2/Episode 6 - LED matrix/realMatrix/episode6_fritzing.png similarity index 100% rename from Season 2/Episode 6 - LED matrix/episode6_fritzing.png rename to Season 2/Episode 6 - LED matrix/realMatrix/episode6_fritzing.png diff --git a/Season 2/Episode 6 - LED matrix/ledData.h b/Season 2/Episode 6 - LED matrix/realMatrix/ledData.h similarity index 100% rename from Season 2/Episode 6 - LED matrix/ledData.h rename to Season 2/Episode 6 - LED matrix/realMatrix/ledData.h diff --git a/Season 2/Episode 6 - LED matrix/readme.md b/Season 2/Episode 6 - LED matrix/realMatrix/readme.md similarity index 100% rename from Season 2/Episode 6 - LED matrix/readme.md rename to Season 2/Episode 6 - LED matrix/realMatrix/readme.md diff --git a/Season 2/Episode 6 - LED matrix/realMatrix.ino b/Season 2/Episode 6 - LED matrix/realMatrix/realMatrix.ino similarity index 100% rename from Season 2/Episode 6 - LED matrix/realMatrix.ino rename to Season 2/Episode 6 - LED matrix/realMatrix/realMatrix.ino