I am trying to install the heroku-cli
I am on mac and I am using npm to install it.
npm install -g heroku
After installing I run the command heroku and the response I receive is:
zsh: command not found: heroku
I have been searching the internet for an answer for way too long now and can not seem to resolve this issue..
I have also downloaded the macOs tarbells and when I open the file, navigate to the bin folder and open the file "heroku" it opens my terminal and display this message.
Even after what looks like it has successfully been installed, when I type heroku --version I still get the command not found.
I am not the most experienced in this field. The reason I am trying to download heroku is because I am doing Fullstack Open.
I just hope it is an easy fix and someone more experienced than me can guide me in the right direction.
I should add I have tried uninstalling and reinstalling multiple times.
SOLUTION FOUND: The solution that helped me was installing homebrew and after installing I ran the command:
brew tap heroku/brew && brew install heroku
heroku command not
npm i -g heroku
zsh: command not found npm:
export NVM_DIR=~/.nvm
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh
zsh: command not
PATH=/bin:/usr/bin:/usr/local/bin:${PATH}
export PATH
I am using a mac and have been following the instruction on how to set up a Big commerce stencil development environment posted here:
https://stencil.bigcommerce.com/docs/prerequisites
When trying to launch stencil:
stencil start
in the template directory called "airflow" - see screenshot for the directory structure - I receive:
-bash: stencil: command not found
directory structure
I have been trough the trouble shooting pages
and verified I have the correct versions of npm, node and nvm
npm -v
2.14.20
node -v
v4.4.0
I have also confirmed there is only one version of node installed:
ls ~/.nvm/versions/node
v4.4.0
Is there any advice anyone can give on how to troubleshoot this?
Many Thanks
Are you sure you installed stencil-cli globally? Run npm ls -g --depth=0 and confirm that #bigcommerce/stencil-cli is listed. If not, install it with the -g flag...ie: npm install -g #bigcommerce/stencil-cli
Second, make sure you're running the stencil commands in the directory that contains the .stencil file...in your screenshot that'd be the "stencil" directory inside of "airflow".
Hope this helps!
I installed truffle through npm with the following:
sudo npm install -g truffle
but when I run truffle list on the console it just gives me
bash: truffle: command not found
I had a similar problem. I ran npm i -g truffle and then when I tried to run truffle init I got an error: zsh: command not found: truffle. What solved it for me is to create a local node_modules with truffle installed in it, and then run that copy.
run npm init and make a new npm project
run npm i truffle
run ./node_modules/.bin/truffle init and it should work!
Please make sure you have the latest version of npm and node installed. I had the same issue, I updated npm and node to latest version and it worked.
npm install -g truffle works.
After installing truffle:
npm install -g truffle
Run on your project folder:
npx truffle init
I did it on a Virtual box and had the same issue, but it worked after I restarted the computer. Hopefully that works for you too
You should add the following to your path system variable.
C:\Users\UserName\AppData\Roaming\npm
(This folder contains the truffle.cmd file)
I have tried and it works.
I tried everything. Followed the instruction on official truffle website and above answers.
Still it didn't seem to worked.
Finally, this worked for me.
Go to C:\Users\Username\AppData\Roaming\npm
There you will find truffle.cmd Double click on it and your done.
npm i truffle does the exact same thing as npm install -g truffle except that installs it globally, and without -g it will be installed on the local folder. Try to update the npm, node, and probably you have a broken node installation from previous versions.
Using npm install -g truffle worked for me instead of npm i truffle
Nothing above worked for me, but I did:
nix truffle unbox react
truffle develop
atom . //opens up the react file project in the atom platform
Try to start with your command like
npx truffle <your command>
You should add C:\Users\UserName\AppData\Roaming\npm (it contains truffle.cmd file) to the path user variables. I have tried and it works
If you have a custom path for your packages, then make sure that you are exporting it when the terminal loads.
For bash:
nano ~/.profile
For zsh:
nano ~./zshrc
And add your custom path, most of the time this will be "npm-global".
export PATH=~/.npm-global/bin:$PATH
These are two simple steps the properly solve this problem for Linux Users:
1- Configure npm to install software globally in your home directory as follows :
mkdir ~/.npm-global
npm config set prefix '~/.npm-global'
2- If you are using bash, then execute the following:
echo -n "export PATH=~/.npm-global/bin:$PATH" >> ~/.profile
However, if you are using zsh instead, then execute the following command:
echo -n "export PATH=~/.npm-global/bin:$PATH" >> ~/.zshrc
Note that, if you are using both bash and zsh, it is better to execute the two commands above.
Like a lot of people I am also having issues with Yeoman.
Error -bash: yo: command not found in OSx.
I tried adding export PATH=/usr/local/share/npm/bin:$PATH on my .bash_profile as suggested by some folks and still same error.
I've lost 2 hours of my productivity trying to fix Yeoman bugs and still nothing.
Does anyone know any good solution that fixes the -bash: yo: command not found ?
I found that for recent versions of npm, all node packages are installed in the ~/npm/bin/ directory.
So add those lines to your $PATH in the .profile file :
export PATH=$PATH:~/npm/bin
Then do :
source ~/.profile
yo -v
Finally found a solution for this.
First I had to uninstall and install yo again:
npm remove -g yo
npm install -g yo
I also added a symlink to the bash_profile to make yo work. The following line: PATH=${PATH}:~/.node/bin After that restart the prompt for the change to take action.
Please check this for more references: Why are my Yeoman generators installing in the wrong place?
try to add an symbolic-link (ln -s) into the /sbin -directory.
like:
ln -s /sbin/ /usr/local/share/npm/bin/yo
This also seems to work :)
sudo `yo angular2-ts [appname]`
where [appname] is the name of your app (without the []) :)
just give access for the user to read write execute in the folder webapp
sudo chmod 777 webapp
cd webapp
yo angular [appname]
I am trying to install urturn api and write my own expression for urturn.com
following http://webdoc.github.com/urturn-expression-api/#!guides/start
After:
npm install urturn-toolbelt -g
I am trying to run sandbox with:
ur sandbox
and got error:
-bash: ur: command not found
Please help
P.S. I am on Mac Os
thanks
It is likely your nodeJS npm/bin folder that is not included in your PATH.
Can you check your PATH variable?
Node NPM package bin files are all symlinked in the same ./bin folder. If you installed NodeJS using Homebrew (brew install node), it should be /usr/local/share/npm/bin.
You can echo your current path using:
echo $PATH
If the folder above does not appear in the list, check your .bashrc or .bash_profile files and fix any problem.
A fix that is likely to work is to add the following line in ~/.bash_profile
PATH=$PATH:/usr/local/share/npm/bin