{"action":"closed","issue":{"url":"https://api.github.com/repos/aspnet/Tooling/issues/406","repository_url":"https://api.github.com/repos/aspnet/Tooling","labels_url":"https://api.github.com/repos/aspnet/Tooling/issues/406/labels{/name}","comments_url":"https://api.github.com/repos/aspnet/Tooling/issues/406/comments","events_url":"https://api.github.com/repos/aspnet/Tooling/issues/406/events","html_url":"https://github.com/aspnet/Tooling/issues/406","id":134006972,"number":406,"title":"External Web Tools paths not respected in prepublish","user":{"login":"danwad","id":533281,"avatar_url":"https://avatars.githubusercontent.com/u/533281?v=3","gravatar_id":"","url":"https://api.github.com/users/danwad","html_url":"https://github.com/danwad","followers_url":"https://api.github.com/users/danwad/followers","following_url":"https://api.github.com/users/danwad/following{/other_user}","gists_url":"https://api.github.com/users/danwad/gists{/gist_id}","starred_url":"https://api.github.com/users/danwad/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/danwad/subscriptions","organizations_url":"https://api.github.com/users/danwad/orgs","repos_url":"https://api.github.com/users/danwad/repos","events_url":"https://api.github.com/users/danwad/events{/privacy}","received_events_url":"https://api.github.com/users/danwad/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/aspnet/Tooling/labels/TFS%20Tracked","name":"TFS Tracked","color":"009800"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2016-02-16T15:13:59Z","updated_at":"2016-04-06T18:13:03Z","closed_at":"2016-04-06T18:13:03Z","body":"Some of my gulp tasks require a later version of node than the included v0.10.31 in VS 2015 Update 1.\r\n\r\nAs mentioned in #101 we can configure the priority of paths VS will search when looking for node in Tools->Options->Projects and Solutions->External Web Tools.\r\n\r\nHowever, when publishing, `C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\Common7\\IDE\\extensions\\microsoft\\web tools\\external` is prepended to the PATH and the prepublish script fails due to node v0.10.31.\r\n\r\nA workaround is to put everything in a script and modify PATH.\r\n\r\nproject.json :\r\n\r\n    ...\r\n      \"scripts\": {\r\n        \"prepublish\": [\"prepublish\"]\r\n      }\r\n    ...\r\n\r\nprepublish.cmd :\r\n\r\n    set PATH=C:\\Program Files\\nodejs;.\\node_modules\\.bin;%PATH%\r\n    \r\n    call npm install || goto :error\r\n    call bower install || goto :error\r\n    call gulp clean || goto :error\r\n    call gulp min || goto :error\r\n    goto :EOF\r\n    \r\n    :error\r\n    echo Failed with error #%errorlevel%.\r\n    exit /b %errorlevel%\r\n\r\nIs there a real workaround or setting to change the PATH which is used when executing prepublish scripts?"}}