so I use atom, I have installed script and when i try to execute my javascript I get this error:
[Command: cmd '/c C:\Users\Stelios\.atom\packages\script\node_modules\.bin\babel --filename C:\Users\Stelios\.atom\packages\script\node_modules\.bin\babel < C:\Users\Stelios\AppData\Local\Temp\atom_script_tempfiles\08a4ca80-fe01-11e8-bc01-85e8d2a83c37.js| node']
'node"' is not recognized as an internal or external command,
operable program or batch file.
[Finished in 0.075s]
Any thoughts how to fix this? I created a folder called node.js in program files set a path and it did not work..
Node is not recognized means either node is not installed or path is not set.
So install Node JS on your Windows machine from https://nodejs.org/en/download/
Check out this guide on how to install Node properly while setting path - https://blog.teamtreehouse.com/install-node-js-npm-windows
Related
I am on a Windows 10 machine. I installed node from the node.js website. Node.js did not add the path to the path environment variable, and the node command didn't work in either powershell or the command prompt. Node.js installed at C:\Program Files\nodejs. I added this path to the path environment variable, and now it works in powershell but it fails when I try to run in in the command prompt.
When I try to use yarn create next-app --typescript in powershell, it says that 'node' is not recognized as an internal or external command,
operable program or batch file.
When I try to check the version of nodejs by running he command in my terminal "node -v" its shows 'node' is not recognized as an internal or external command,
operable program or batch file. I tried to set the path but the nodejs folder is not in my pc. Please help me out.enter image description here
I'm new here to Typescript and I'm trying to install it globally on my machine.
I currently have the following versions:
Node v.11.13.0
npm v6.7.0
When I run npm install -g typescript I get the following results:
C:\Users[userid].node_modules_global\tsc ->
C:\Users[userid].node_modules_glob al\node_modules\typescript\bin\tsc
C:\Users[userid].node_modules_global\tsserver ->
C:\Users[userid].node_modules
_global\node_modules\typescript\bin\tsserver
+ typescript#3.4.2 updated 1 package in 3.297s
The moment I run tsc or tsc -v on my command line, I receive the
'tsc' is not recognized as an internal or external command, operable
program or batch file.
I have uninstalled node and reinstalled it, but I still get the same error.
I have consulted Google and followed other methods on Stackoverflow to fix this problem, including checking the PATH folder structure.
I am not sure what I am doing wrong here, please help.
FYI I am running a Windows 7 PC.
In your command prompt, try executing the below command,
set path=%PATH%;c:\Users\YOUR_USER_DIRECTORY\AppData\Roaming\npm;
Then try executing your tsc command again, you will get it executed now.
Hope this helps!
FOUND IT!
Ok so I dug around and discovered the following:
Under User\[pc_name]\.node_modules_global I found the tsc and tsc.mcd files. All I did was copy those two files across to ...\Roaming\npm.
After doing that I ran tsc in my command prompt and it worked!
So I'm having a lot of trouble getting my node module command line commands to run correctly.
For example if I try and run gulp I get a
>gulp
'gulp' is not recognized as an internal or external command,
operable program or batch file.
So I have tried making my environment variable NODE_PATH
%APPDATA%\npm\node_modules\
%APPDATA%\npm\node_modules
%APPDATA%\npm
but none of these seem to work. The only command I can use to get my gulp to run with is
C:\Users\Aaron\Documents\GitHub\2015fallTeam14>node %NODE_PATH%gulp\bin\gulp
[12:10:32] Using gulpfile ~\Documents\GitHub\2015fallTeam14\gulpfile.js
It would appear that cmd is not running my node with my NODE_PATH variable along with my command, but I do not know how to to fix this
You need to set the system PATH variable to tell the command prompt where to find gulp.bat (which npm creates).
This has nothing to do with Node itself.
I had add the following
Edit "PATH" environment variable and add %APPDATA%\npm
from
https://stackoverflow.com/a/27295145/4249440
Im not sure why this works though. I would like to know how the cmd knows to run node on this file path.
I've installed vows as module of my project and I've added the path "node_modules\vows\bin" to my environment path variable of windows vista.
note: I've also renamed "node_modules\vows\bin\vows" to vows.exe, because without the extension I get this error: 'vows' is not recognized as an internal or external command,
operable program or batch file.
Now wherever I put "vows" in my cmd in windows nothing happens, I cd into my test folder and I run "vows myFirstTest.js" and nothing happens. (when I say nothing happens my cursor in cmd is going to the top and then return to it's original position and it's doing this forever, therefore each time I try a vows command in cmd I have to close the cmd to run another command).
What I'm doing bad?
thanks
NPM is great at globally installing packages and making the executable for each operating system (UNIX-ish + Windows), so proceed with the following:
npm install -g vows