Skip to content

Set installed property for installed platform when core search is executed #2223

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

Merged

Conversation

MatteoPologruto
Copy link
Contributor

@MatteoPologrutoMatteoPologruto commented Jun 21, 2023

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)
  • configuration.schema.json updated if new parameters are added.

What kind of change does this PR introduce?

Code enhancement

What is the current behavior?

The installed property is never set.

./arduino-cli core install arduino:avr --format json 
./arduino-cli core search "" --format json | jq '.[] | select(.id == "arduino:avr") | .installed' null 

What is the new behavior?

The installed property is set if the platform is installed.

./arduino-cli core install arduino:avr --format json 
./arduino-cli core search "" --format json | jq '.[] | select(.id == "arduino:avr") | .installed' "1.8.6" 

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

No

@MatteoPologrutoMatteoPologruto added type: enhancement Proposed improvement topic: code Related to content of the project itself labels Jun 21, 2023
@MatteoPologrutoMatteoPologruto self-assigned this Jun 21, 2023
@MatteoPologrutoMatteoPologruto changed the title Set installed property for installed platform when core search is executed Set installed property for installed platform when core search is executed Jun 21, 2023
@codecov
Copy link

codecovbot commented Jun 21, 2023

Codecov Report

Patch coverage: 100.00% and no project coverage change.

Comparison is base (9bc2afc) 62.95% compared to head (641f64e) 62.95%.

Additional details and impacted files
@@ Coverage Diff @@## master #2223 +/- ## ======================================= Coverage 62.95% 62.95% ======================================= Files 220 220 Lines 19476 19478 +2 ======================================= + Hits 12261 12263 +2  Misses 6132 6132 Partials 1083 1083 
FlagCoverage Δ
unit62.95% <100.00%> (+<0.01%)⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted FilesCoverage Δ
commands/core/search.go84.21% <100.00%> (+0.57%)⬆️

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@MatteoPologrutoMatteoPologruto marked this pull request as ready for review June 21, 2023 11:22
@MatteoPologrutoMatteoPologruto linked an issue Jun 21, 2023 that may be closed by this pull request
3 tasks
@MatteoPologrutoMatteoPologruto merged commit eca9d9a into arduino:masterJun 21, 2023
@MatteoPologrutoMatteoPologruto deleted the core-search-set-installed branch June 21, 2023 16:07
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: codeRelated to content of the project itselftype: enhancementProposed improvement
3 participants
@MatteoPologruto@cmaglie@alessio-perugini
close