Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor additional entries #32

Merged
merged 6 commits into from
Aug 31, 2023

Conversation

alessio-perugini
Copy link

Please check if the PR fulfills these requirements

See how to contribute

  • The PR has no duplicates (please search among the Pull Requests
    before creating one)
  • The PR follows
    our contributing guidelines
  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been added / updated (for bug fixes / features)
  • UPGRADING.md has been updated with a migration guide (for breaking changes)

What kind of change does this PR introduce?

What is the current behavior?

What is the new behavior?

Does this PR introduce a breaking change, and is titled accordingly?

Other information

@cmaglie cmaglie merged commit 90994dd into cmaglie:builder_refactor Aug 31, 2023
87 checks passed
@cmaglie cmaglie deleted the refactor_additional_entries branch August 31, 2023 18:22
cmaglie pushed a commit that referenced this pull request Sep 5, 2023
#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
cmaglie added a commit to arduino/arduino-cli that referenced this pull request Sep 6, 2023
* 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

cmaglie#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: Alessio Perugini <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants