Fly command won't work after installing flight plan - node.js

So I was working through a tutorial to deploy my node app to a server. They had me npm install flightplan -g so I can use the 'fly' command. This all worked but for the fly command to work I needed to install rsync. I finally got rsync to work after changing my PATH. But now when I use to fly command I get "'fly' is not recognized as an internal or external command,
operable program or batch file."
I've tried changing the PATH hundreds of times to different things and I can't for the life of my get the fly command to work again. I've tried reinstalling flightplan globally a bunch of times. NOTHING IS WORKING.

Node JS NPM modules installed but command not recognized
This was the answer I was looking for.. I had the end of my path set to npm/fly and not just npm....

Related

'tsc' is not recognized as an internal or external command, operable program or batch file. - Windows 7

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!

Node.js - "node" command works, but not when through another framework

I have Node.js + NPM installed; I can run node -v in my console and get back the current version.
I have also tried using NVM Windows as a Node.js version manager and can run both node -v and npm -v there as well.
HOWEVER, when trying to use another framework like Gulp or Ionic or whatever, I keep getting the error:
'node' is not recognized as an internal or external command,
operable program or batch file.
node is obviously a cmdlet as I can run node -v.. but somehow my other frameworks are no longer able to find it.
Path is correct and everything looks good.
What am I missing here?
The program ConEmu for windows terminal management wasn't pulling or allowing programs to access the paths through subcalls or something it seems. I tested with CMD and Powershell respectively and both worked as expected.
I couldn't get ConEmu to seemingly pass these path to subroutines.. so I uninstalled it and found an alternative called Cmder that is built on ConEmu and it was able to pick them up just fine.
I don't know specifically if it was just a setting in ConEmu I couldn't find or if I needed to manually add these--but happy knowing Cmder just does it automatically.

'tsc' is not recognized as an internal or external command on Windows when installed globally

I've seen bunch of 'tsc' is not recognized as an internal or external command issues here on StackOverflow but none of them could help me solve my problem.
I've installed typescript globally with:
npm install -g typescript
There are tsc and tsc.cmd files in C:\Users\<user_name>\AppData\Roaming\npm directory. So %AppData%\npm\tsc --version command works.
I've got C:\Users\<user_name>\AppData\Roaming\npm directory in my user's PATH.
More, when I run where tsc command in arbitrary directory, I get:
C:\Users\<user_name>\Desktop>where tsc
C:\Users\<user_name>\AppData\Roaming\npm\tsc
C:\Users\<user_name>\AppData\Roaming\npm\tsc.cmd
However, when I simply try to run tsc, I got:
C:\Users\<user_name>\Desktop>tsc
'tsc' is not recognized as an internal or external command,
operable program or batch file.
Exactly the same problem occurs with grunt and uglifyjs.
I managed to solve this problem.
C:\Users\<user_name>\AppData\Roaming\npm indeed was in user's PATH variable. I also have system variable called Path (yes, just first letter is uppercased) and there was no C:\Users\<user_name>\AppData\Roaming\npm in there.
When I added it to system's Path, it finally started to work.
Not sure that this is ok that two of my path variables have different names (in terms of cases). Also not sure that this situation led to problems.
Would be glad if someone could clarify this.
Try installing the linux console for windows the cygwin console., And run the command tsc from that console, I know it does not change much but sometimes I have solved many problems with that console.
https://www.cygwin.com/

Grunt on Windows 8: 'grunt' is not recognized

I'm having a problem running Grunt from the command line on my Windows 8 machine.
My research indicates the most common solution is to install grunt-cli, since Grunt is no longer global. I also need to make sure I actually install the Grunt task runner, since that's not installed with grunt-cli.
Other solutions point to the PATH system environment variable, but that appears to be pointed as I'd expect to:
C:\Users[username]\AppData\Roaming\npm
Having done all that, I'm still getting a "'grunt' is not recognized as an internal or external command, operable program or batch file" error message in the CLI. I've tried the following things, uninstalling everything after every attempt:
Installed grunt-cli globally (npm install -g grunt-cli), then grunt at the directory level I want to use it (npm install grunt)
The same as above, but with the order of installation reversed
The same as both of the above, but using the Admin Command Prompt
Am I missing something obvious?
I've not had any issues with grunt on several different windows 8 machines.
If you open the folder: C:\Users\[username]\AppData\Roaming\npm
Do you have a file named grunt.cmd in this folder?
If not I'd maybe try npm install -g grunt-cli again, maybe from an elevated command prompt.
If this exists and you have C:\Users\[username]\AppData\Roaming\npm in your PATH environment variable then typing grunt from a command prompt should work.
Silly question, have you tried closing the command prompt and opening a new one?
Confirm your PATH is correct (and not messed up). Just type PATH from the command prompt. There's really no other explanation that makes sense given the error you're describing and the steps you've taken.
Normally, using the where grunt command would have found grunt.cmd in your path if npm is installed correctly and it has been properly added to the system path.
Close all Command Prompt instances.
Start a new Command Prompt instance.
Type PATH Enter and verify if C:\Users\Username\AppData\Roaming\npm is part of the path.
If not, you need to log off and on again,or close the Command Prompt and restart the explorer process.
In the Command Prompt, type where grunt Enter.
You're good if it reports:
C:\Users\Username\AppData\Roaming\npm\grunt
C:\Users\Username\AppData\Roaming\npm\grunt.cmd
Otherwise, you have to reinstall the grunt-cli package if it reports:
INFO: Could not find files for the given pattern(s).
Apparently, programs that change the PATH environment variable must broadcast a WM_SETTINGCHANGE message. The Windows' System settings window does it correctly when you change the PATH variable, but the NPM installer doesn't. That's why you have to restart explorer (or log off or restart, which has the same effect).
I know this has been answered but I thought I'd offer my step by step solution for windows 8.
First thing I checked was the PATH in my laptops Environment Variables (Right click my computer > properties > advanced system settings > Environment Variables)
It wasn't listed in there so I added a new variable in User variables (so it was specific only to my user account)
In the new user variable prompt I entered the following;
Variable Name: PATH
Variable Value: %USERPROFILE%\AppData\Roaming\npm
Quit command prompt, repoened, navigated to my projects directory and tried running grunt again and... SUCCESS!
I had the same issue.
I tried different things:
Restart computer
Deleted the grunt folder and ran
npm install -g grunt -cli
Didn't work.
Finally tried:
npm install -g grunt-cli
Worked perfectly.
Tried
where grunt
and I saw 2 locations where it was found.
I was facing the same problem on windows 8
I have added ' %APPDATA%\npm ' to the path variable . It has been working fine.
some times NPM install corrupts the basic windows path. i usually have a copy of my own version of PATH mainted separately. every week or on some installs i manually configure and update the %PATH% variable.
Basically Grunt.cmd is not availbe through %PATH% variable.
I have stucked with problem on Windows 8, that after install grunt-cli I've always got "command not found" while I'm tried to check grunt -v or where grunt. So I've added to enviroment PATH this path C:\Program Files (x86)\Git\local and run grunt.cmd from that folder (you need to look in node_modules folder here). And after reloading my terminal everything started to work.
Same happened to me and here was the solution:
Have you got 2 different versions of Node.JS installed?
Maybe Nodist?
This means you likely got NPM installed twice which will install the commands into 2 different folders:
Once into C:\Users\<user>\AppData\Roaming\npm and once into C:\dev\nodist\bin\bin.
C:\dev\nodist\bin\bin wasn't on my path variable so I added it, and I removed the Node.JS version I didn't want to use.
If you have no grunt.cmd file created by npm, make sure that you do not have a .npmrc in your home directory with: bin-links=false in it.
After getting a tonne of "'grunt' is not recognized as an internal or external command," errors, I solved this on Windows 10 by going to Path and adding C:\Users\Username\AppData\Roaming\npm

I can't run test with "vows test/*" command on windows. How to use it? node.js

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

Resources