Npm task doesn't work on windows agents

Issue #31 resolved
Scott Goodhew created an issue

The resolution to #29 (ae7fbdfaf724) was to prefix all npm tasks with the node executable. This doesn't work on Windows agents because the npm executable isn't a javascript file it's a batch file.

This causes build failures like https://devtools-bamboo.internal.atlassian.com/browse/STASH-IT-TWX-958/log

Comments (4)

  1. Adam Ahmed Account Deactivated

    If it helps, this is the contents of that batch file :

    :: Created by npm, please don't edit manually.
    @IF EXIST "%~dp0\node.exe" (
      "%~dp0\node.exe" "%~dp0\.\node_modules\npm\bin\npm-cli.js" %*
    ) ELSE (
      node "%~dp0\.\node_modules\npm\bin\npm-cli.js" %*
    )
    

    So you can just call npm-cli.js directly on Windows (and keep the node prefix if you want).

  2. Marcin Oles

    @samuel_tannous I'm closing this ticket, as the corresponding BDEV issue got resolved and I see commits with the fix.

  3. Log in to comment