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

"dependsOn " doesn't work in Global task.json in new version 1.42 #90286

Closed
hwhsuguest opened this issue Feb 8, 2020 · 1 comment
Closed
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug tasks Task system issues verified Verification succeeded
Milestone

Comments

@hwhsuguest
Copy link

  • VSCode Version: 1.42
  • OS Version: Windows 10

I want to "mkdir build" before "cmake"
So I design 2 tasks in Global task.json
Here are my tasks

> {
>     "label": "CMake/Make (MinGW)",
>     "type": "shell",
>     "group": "build",
>     "command": [
>         "cmake -G \"MinGW Makefiles\" -S . -B build",
>         "&&",
>         "mingw32-make -j8 -C build"
>     ],
>     "dependsOn":["mkdir build"],
>     "problemMatcher": "$gcc",
> },
> {
>     "label": "mkdir build",
>     "type": "shell",
>     "group": "build",
>     "command": "mkdir build",
> },

However, when I run the "CMake/Make (MinGW)", TERMINAL panel shows that

> The terminal shell CWD "d:\HW_VSC\VSC-CMAKE-MINGW64\Seperate_CMakLists_TEST\build" does not exist

So I check the OUTPUT panel. it shows that

> Couldn't` resolve dependent task 'mkdir build' in workspace folder

To chek whether my code is wrong,
I copy the code to the Local tasks.json in .\\.vscode
I run it, and it works!!!

Besides, I found that Global task can "dependsOn" Local task,
But it cannot "dependsOn" Global task

@vscodebot
Copy link

vscodebot bot commented Feb 8, 2020

(Experimental duplicate detection)
Thanks for submitting this issue. Please also check if it is already covered by an existing one, like:

@alexr00 alexr00 added bug Issue identified by VS Code Team member as probable bug tasks Task system issues labels Feb 10, 2020
@alexr00 alexr00 added this to the February 2020 milestone Feb 10, 2020
@JacksonKearl JacksonKearl added the verified Verification succeeded label Feb 28, 2020
@github-actions github-actions bot locked and limited conversation to collaborators Apr 6, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug tasks Task system issues verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

3 participants