# How to update node-red-contrib-powershell

**URL:** <https://discourse.nodered.org/t/how-to-update-node-red-contrib-powershell/53214>\
**Category:** General\
**Created:** [4 November 2021 13:26 UTC](https://discourse.nodered.org/t/how-to-update-node-red-contrib-powershell/53214 "2021-11-04T13:26:43Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![RainerGa](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/rainerga/32/50441_2.png) [@RainerGa](https://discourse.nodered.org/u/RainerGa)\
**Post date:** [4 November 2021 13:26 UTC](https://discourse.nodered.org/t/how-to-update-node-red-contrib-powershell/53214/1 "2021-11-04T13:26:43Z")

</div>

Hello,

again I spend over 2 hours to debugging.

The Package "node-red-contrib-powershell" has a bug. The msg.payload will not correct returned.

In github the error is corrected, see: [node-red-contrib-powershell/powershell.js at master · tobiassoltermann/node-red-contrib-powershell · GitHub](https://github.com/tobiassoltermann/node-red-contrib-powershell/blob/master/powershell.js)

The correction was 12 Dec 2019!

Please guide me in the right direction. Is it wrong to use the Packages which I can install with the "add palette" button?

And how did you work?

Spend hours and hours and analyse the sourcecode seams a bit time consuming for me.

Kind regards

Rainer

---

<div class="post-metadata">

**Author:** ![cymplecy](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cymplecy/32/2773_2.png) [@cymplecy](https://discourse.nodered.org/u/cymplecy)\
**Post date:** [4 November 2021 14:21 UTC](https://discourse.nodered.org/t/how-to-update-node-red-contrib-powershell/53214/2 "2021-11-04T14:21:33Z")

</div>

If the npm package hasn't been updated with the fix maybe raise an issue on GitHub to point this out to the author

---

<div class="post-metadata">

**Author:** ![RainerGa](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/rainerga/32/50441_2.png) [@RainerGa](https://discourse.nodered.org/u/RainerGa)\
**Post date:** [4 November 2021 14:24 UTC](https://discourse.nodered.org/t/how-to-update-node-red-contrib-powershell/53214/3 "2021-11-04T14:24:00Z")

</div>

Hello Simon,

thanks for your hint. I will try this.

Are you doing this the same way or have you identified a better solution in your workflow?

---

<div class="post-metadata">

**Author:** ![cymplecy](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cymplecy/32/2773_2.png) [@cymplecy](https://discourse.nodered.org/u/cymplecy)\
**Post date:** [4 November 2021 14:25 UTC](https://discourse.nodered.org/t/how-to-update-node-red-contrib-powershell/53214/4 "2021-11-04T14:25:43Z")

</div>

I dont use it

If you need to use it before npm gets updated then maybe you could install it direct from the repository

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [4 November 2021 14:48 UTC](https://discourse.nodered.org/t/how-to-update-node-red-contrib-powershell/53214/5 "2021-11-04T14:48:20Z")

</div>

You can install direct from github by going into your .node-red folder (that is important) and running  
`npm install tobiassoltermann/node-red-contrib-powershell`

---

<div class="post-metadata">

**Author:** ![RainerGa](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/rainerga/32/50441_2.png) [@RainerGa](https://discourse.nodered.org/u/RainerGa)\
**Post date:** [4 November 2021 14:53 UTC](https://discourse.nodered.org/t/how-to-update-node-red-contrib-powershell/53214/6 "2021-11-04T14:53:26Z")

</div>

This is great! THANK YOU!

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [4 November 2021 16:23 UTC](https://discourse.nodered.org/t/how-to-update-node-red-contrib-powershell/53214/7 "2021-11-04T16:23:31Z")

</div>

You could also use the node-powershell underlying library direct in a function node without the simplistic wrapper that the contrib node provides.

In truth though, you are probably better off simply using the exec node to execute powershell directly.

There is also a different node.js module that I've always recommended for Node/PowerShell interactions: edgejs.

This is a fork of edgejs with some improvements: [edge-js - npm (npmjs.com)](https://www.npmjs.com/package/edge-js)

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [18 November 2021 16:23 UTC](https://discourse.nodered.org/t/how-to-update-node-red-contrib-powershell/53214/8 "2021-11-18T16:23:41Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
