Skip to content

Error to locate grunt.cmd #27

Description

@fredgate

Since commit eee037c, search of grunt.cmd path fails when the where command is used.
The reason is that the ConsoleToMsBuild attribute has been removed from Exec task so the TaskParameter named ConsoleOutput is no longer filled and the GruntExecutable becomes empty. No error is detected because the command is successfully executed and the ExitCode is 0.
But the GruntExecutable is undefined and the execution of the grunt file failed.

The Grunt target should be restored as it :

         <Exec Command="$(WINDIR)\system32\where.exe grunt"
             ContinueOnError="true"
             IgnoreExitCode="true"
             ConsoleToMsBuild="true"
             Condition=" !Exists('$(GruntExecutable)') ">
             <Output TaskParameter="ExitCode" PropertyName="GruntExitCode" />
             <Output TaskParameter="ConsoleOutput" PropertyName="GruntExecutable" />
         </Exec>

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions