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

[Feature Request]: Automatic platform detection. (VSC-1580) #1416

Open
SinglWolf opened this issue Jan 30, 2025 · 2 comments
Open

[Feature Request]: Automatic platform detection. (VSC-1580) #1416

SinglWolf opened this issue Jan 30, 2025 · 2 comments
Assignees
Labels
Feature / Enhancement Request Request for Feature/ Enhancement

Comments

@SinglWolf
Copy link

SinglWolf commented Jan 30, 2025

Greetings!
There are a lot of similar lines in the vscode-esp-idf-extension settings that confuse beginners and greatly annoy more experienced users (e.g., me)
Image
Image
Image

Using the example of typescript, I propose a solution to the problem with different delimiters in the path, depending on the platform on which vscode-esp-idf-extension is running.

import * as os from 'os';

const platform = os.platform();

if ((platform === "linux") || (platform === "darwin")){
    // linux or OS X
   // e.g.
    SLASH = '/';
}else if (platform === "win32"){
    // Windows...
   // e.g.
    SLASH = '\\';
}

This will allow to show only the necessary elements in the vscode-esp-idf-extension settings.

@SinglWolf SinglWolf added the Feature / Enhancement Request Request for Feature/ Enhancement label Jan 30, 2025
@github-actions github-actions bot changed the title [Feature Request]: Automatic platform detection. [Feature Request]: Automatic platform detection. (VSC-1580) Jan 30, 2025
@radurentea
Copy link
Collaborator

Greetings @SinglWolf,

Thank you for this feature request. To make sure I understand your proposal correctly:

Are you suggesting that the extension should automatically detect the platform and:

  • Only show relevant platform-specific settings in the VS Code settings UI? Or to have different descriptions, so that the user would understand what's the difference between "idf: Build Path" and "idf: Build Path Win" for example?
  • Automatically handle path delimiter conversion internally (/ vs ) without requiring separate settings for each OS?

@radurentea radurentea self-assigned this Feb 3, 2025
@SinglWolf
Copy link
Author

SinglWolf commented Feb 3, 2025

  • Only show relevant platform-specific settings in the VS Code settings UI and automatically handle path delimiter conversion internally (/ vs ) without requiring separate settings for each OS

An acceptable option

  • Or to have different descriptions, so that the user would understand what's the difference between "idf: Build Path" and "idf: Build Path Win" for example?

This only leads novice users into a stupor from the huge number of almost identical lines. And others will probably wonder why, if everything can be done automatically, without user intervention.

I've been working of ESP chips since 2013. It's my hobby. Until recently for my, the VS Code + PlatformIO bundle was the perfect solution for ESP programming and firmware. From time to time, I installed vscode-esp-idf-extension and tried to work with it. Alas, unsuccessfully.
I tried again a while ago. And I did it. I was even able to set up a multi-project. Good job.
The vscode-esp-idf-extension still has many "childhood illnesses", but now we can say with confidence that the extension has gained momentum and I am happy to contribute to the development of the project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature / Enhancement Request Request for Feature/ Enhancement
Projects
None yet
Development

No branches or pull requests

2 participants