Git Product home page Git Product logo

Comments (8)

VSCodeTriageBot avatar VSCodeTriageBot commented on July 20, 2024

Thanks for creating this issue! It looks like you may be using an old version of VS Code, the latest stable release is 1.89.1. Please try upgrading to the latest version and checking whether this issue remains.

Happy Coding!

from vscode.

roblourens avatar roblourens commented on July 20, 2024

What exactly is the scenario- how are you moving settings between machines?

This setting is a "machine"-scoped setting, meaning Settings Sync won't sync it between machines when configured in your user settings. You can configure it once per machine and leave it alone.

I don't think we should change how this works, otherwise you could make the same argument for many other settings.

from vscode.

AshuMaster avatar AshuMaster commented on July 20, 2024

I use Windows for my desktop and macOS for my laptop, and I have the same project set up on both systems. The project depends on PHP, but the PHP executable paths differ between the two operating systems. I use the official VS Code Settings Sync with my GitHub account to ensure my settings remain consistent across machines. However, I encountered an issue with the php.validate.executablePath setting, as it doesn't support multiple paths.

For instance:

On Windows, the path is C:/xampp/php/php.exe.
On macOS, the path is /Applications/XAMPP/xamppfiles/bin/php.

Each day, before starting work on either system, I have to manually update the PHP path in the settings, which disrupts my workflow.

Is it possible to enhance the php.validate.executablePath setting to support an array of paths? This way, VS Code will check each path in order until it finds a valid PHP executable. Here’s an example of what this could look like:

"php.validate.executablePath": [
{
"path": "C:/xampp/php/php.exe"
},
{
"path": "/Applications/XAMPP/xamppfiles/bin/php"
}
]

This change would greatly simplify the workflow for developers like myself who work across multiple operating systems.

Thank you for considering this suggestion. I appreciate the fantastic work you do with VS Code!

from vscode.

AshuMaster avatar AshuMaster commented on July 20, 2024

Please let me know if you have any other solutions to my problem.

from vscode.

roblourens avatar roblourens commented on July 20, 2024

Are you saying that settings sync is syncing that setting across machines? It should not do that. I just tested and I don't see it being synced.

from vscode.

AshuMaster avatar AshuMaster commented on July 20, 2024

These are the settings in settings.json. As you can see in the screenshot, my current solution is to comment and uncomment the code in VS Code > User > settings.json.

Screenshot

from vscode.

roblourens avatar roblourens commented on July 20, 2024

php.validate.executablePath is a vscode setting that should not be synced. I double-checked this. The other two are from some extension that might set the wrong scope on those settings so they get synced. If so, you can open an issue on that extension.

Can you explain a little more clearly so I can be sure I understand- if you set php.validate.executablePath on your mac, do you then see that same setting with the mac path show up on windows?

You can try running the command "Show Sync Data" and looking for the Settings entry to see what data is being synced

from vscode.

AshuMaster avatar AshuMaster commented on July 20, 2024

Thank you for your time and effort in helping me understand the issue.

After reading your message, I uninstalled and deleted VS Code from both my Windows and iOS systems, including their related hidden extension folders and the main VS Code folder. After reinstalling VS Code, I noticed that the path "php.validate.executablePath": "" is now updating the PHP path correctly on both my Windows and Mac devices. My previous settings had an issue, but everything is functioning correctly now.

I appreciate your help in helping me through this problem.

from vscode.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.