Skip to content

Commit dd64829

Browse files
committed
Ensure library directory existence prior to using it
1 parent 09356c5 commit dd64829

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

CHANGELOG.md

+1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
1818

1919
### Fixed
2020
- Example sketches with no configured platforms were printing the wrong configuration values to the debug message
21+
- Libraries directory was not being automatically created prior to attempting to change directory into it
2122

2223
### Security
2324

exe/arduino_ci.rb

+5
Original file line numberDiff line numberDiff line change
@@ -530,6 +530,11 @@ def perform_example_compilation_tests(cpp_library, config)
530530
config = ArduinoCI::CIConfig.default.from_project_library
531531
@backend = ArduinoCI::ArduinoInstallation.autolocate!
532532
inform("Located arduino-cli binary") { @backend.binary_path.to_s }
533+
if @backend.lib_dir.exist?
534+
inform("Found libraries directory") { @backend.lib_dir }
535+
else
536+
assure("Creating libraries directory") { @backend.lib_dir.mkpath || true }
537+
end
533538

534539
# run any library init scripts from the library itself.
535540
perform_custom_initialization(config)

0 commit comments

Comments
 (0)