• Cristian Maglie's avatar
    [skip-changelog] legacy: Builder refactorization (part 1...) (#2286) · 72c32cac
    Cristian Maglie authored
    * Simplified compileFiles
    
    * Starting new Builder (part 1/n)
    
    * builder: renamed variable and moved dir creation up
    
    * builder: made a sketch-prepress function part of Builder
    
    * Removed ctx dependency in PreprocessSketchWithArduinoPreprocessor
    
    * uniform parameters between preprocesors
    
    * Moved PreprocessSketchWithArduinoPreprocessor into proper place
    
    * Inlined function
    
    * Converted sketchCopyAdditionalFiles into a Builder method
    
    * Made SetupBuildProperties a method of the new Builder
    
    * Refactor AddAdditionalEntriesToContext
    
    https://github.com/cmaglie/arduino-cli/pull/32
    
    * refactor AddAdditionalEntriesToContext in a function
    
    * use the new function in all the tests
    
    * Move the assignaton of LibrariesResolutionResults inside the ResolveLibrary func
    
    The ResolveLibrary func is only called by the ContainerFindIncludes
    
    * rename bPath to buildPath
    
    * cleanup usless tests
    
    * remove shadowed variable
    
    * Refactor legacy LibrariesLoader command
    
    * move LibrariesLoader under arduino/builder
    
    * remove usless nil check
    
    * remove AddAdditionalEntries func, in favour of initializing them in the compile command
    
    * move a check directly in the compile command
    
    * create the SketchLibrariesDetector struct
    
    * move all the logic of ContainerSetupHardwareToolsLibsSketchAndProps in the compile command
    
    * remove container_setup and adjust relative tests
    
    * remove LibraryResolver property from context
    
    * remove UseCachedLibrariesResolution for context
    
    * remove ImportedLibraries from context
    
    * remove LibrariesResolutionResults from context
    
    * remove LibrariesManager from context
    
    * fix regression exceeding 100% status bar
    
    * refactor find_includes
    
    * refactoring the cmd.Exec in favour of executils
    
    * use detector FindIncludes in tests
    
    * add comments and make some plubic methods private
    
    ---------
    Co-authored-by: default avatarAlessio Perugini <alessioper.98@gmail.com>
    72c32cac
utils.go 9.23 KB