sintaxi / surge

CLI for the surge.sh CDN
https://surge.sh
2.87k stars 136 forks source link

Command "surge" cannot be found #414

Open rosenclosed opened 4 years ago

rosenclosed commented 4 years ago

I have installed surge on my Windows 10 machine, I have the latest version of node.js installed. But after installing surge if i run the command "surge" in cmd i get an error

Der Befehl "surge" ist entweder falsch geschrieben oder konnte nicht gefunden werden.

English:

The "Surge" command is either misspelled or not found.

I don't know what I did wrong.

ngdangtu-vn commented 4 years ago

Can you tell me how did you install it?

In case you install it as a local dependency, please use it like this in the folder you installed:

npx surge

If you installed it as a global dependency, it is probably Windows doesn't recognize the global packages location. If I'm correct, global packages should be in C:\node_modules\ with C is OS drive. Referer stackoverflow to learn how to set PATH in Window 10.