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] Support multiple folders open #26

Closed
anasilva105 opened this issue Jun 1, 2023 · 0 comments · Fixed by #59
Closed

[FEATURE] Support multiple folders open #26

anasilva105 opened this issue Jun 1, 2023 · 0 comments · Fixed by #59
Assignees
Labels
Done enhancement New feature or request
Milestone

Comments

@anasilva105
Copy link
Collaborator

Currently the extension can only be executed if the user has open in VSCode a single devtools folder. In the scenario of the user having vscode open with multiple folders the extension won't work.

Solution:
When the user is in a folder with mutiple folders open all the sfmc devtools extension actions should take in consideration the path from the project in order to switch and execute the action in the selected project.

Possible solution: vscode.workspace.workspaceFolders and execSync("cd && mcdev ....")

ensure to change the working directory to the current project's root : https://stackoverflow.com/a/64726585/818732

just in case users have multiple project folders open, you should always match whatever path you get from a context menu execution to then be able to switch the current working directory to the right root folder!
mcdev expected to be executed in the root folder of a project because that's where it will look for the config file .mcdevrc.json and .mcdev-auth.json

as expected, running any context-menu related commands wont bother checking or changing the working directory but simply take whatever terminal is currently open, paste & execute the relevant command. that ends in the following error:
image

@anasilva105 anasilva105 added enhancement New feature or request NEW not yet analyzed new issues get this label labels Jun 1, 2023
@anasilva105 anasilva105 self-assigned this Jun 1, 2023
@anasilva105 anasilva105 added this to the 1.0.0-beta milestone Jun 1, 2023
@anasilva105 anasilva105 modified the milestones: 1.0.0-beta, 0.1.0 Dec 5, 2023
@anasilva105 anasilva105 modified the milestones: 0.1.0, 1.0.0 Dec 13, 2023
@anasilva105 anasilva105 added Done and removed NEW not yet analyzed new issues get this label labels Dec 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Done enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant