holepunchto / pear

combined Peer-to-Peer (P2P) Runtime, Development & Deployment tool
https://docs.pears.com/
Apache License 2.0
91 stars 9 forks source link

win10 pear runtime installation error - Export-ModuleMember cmdlet can only be called from inside a module #25

Closed Valence101 closed 2 weeks ago

Valence101 commented 6 months ago

OS: windows 10 Terminal: windows terminal running in administrator mode

Steps to reproduce:

  1. run npm i -g pear
  2. run pear
  3. run pear run pear://runtime

At this point the pear system status window opens with the "Complete Pear Setup" button. I click the button, but nothing happens.

I then manually added the %userprofile%\AppData\Roaming\pear\bin path to my system PATH environment variables (after watching the tutorial and understanding that is what the "Complete Pear Setup" button is intended to do.

I then return to the terminal and run pear and receive the error message: Export-ModuleMember : The Export-ModuleMember cmdlet can only be called from inside a module.

I look at the file the stack trace points to: %userprofile%\AppData\Roaming\pear\bin\pear.ps1 - the contents of said script file:

function pear { & "..\current\by-arch\win32-x64\bin\pear-runtime" }; Export-ModuleMember -Function pear

Any guidance is much appreciated. Thank you.

mafintosh commented 6 months ago

Thanks, yea windows setup needs some work still. Sorry about that.

davidmarkclements commented 2 weeks ago

fixed