fix set target preview targets #1652
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
#1557 unfortunately introduced a bug, the IDFTarget class was not used in setTargetInIdf.ts so preview targets stopped working (like ESP32C5).
This pull request adds support for new ESP-IDF targets and improves type safety and consistency when selecting and handling targets throughout the codebase. Additionally, there is a minor update to the status bar item background color handling.
ESP-IDF Target Support Improvements
esp32c4,esp32c5, andesp32c61to theIdfTargettype and mapped their CPU watchpoint numbers insrc/cdtDebugAdapter/debugConfProvider.ts. [1] [2]Target Selection Refactoring
setIdfTargetto useIdfTargetfor improved type safety, and refactored how default boards and connected boards are handled when building the selection list insrc/espIdf/setTarget/index.ts. [1] [2]selectedTarget.idfTarget.targetand ensure correct parameter updates when setting the target in the workspace and configuration.UI and Visual Improvements
ThemeIconfor better integration with VSCode theming insrc/statusBar/index.ts. [1] [2]Type of change
Steps to test this pull request
Expected behaviour:
The command should executed correctly and the new target should be applied to sdkconfig and idf.customExtraVars setting.
Expected output:
The command should executed correctly and the new target should be applied to sdkconfig and idf.customExtraVars setting.
How has this been tested?
Test Configuration:
Checklist