WebFaction
Community site: login faq
0
1

I have the out-of-the-box (Webfaction install) Node.js installed in /webapps/node/ and have added the Node.js application's bin directory to my PATH environment variable.

I have another static application in /webapps/application/ which includes a package.json file, with which I was able to successfully run node install, which added the /webapps/application/node_modules folder successfully, and as expected. Now, I should be able to run commands with the node modules that were installed, such as gulp (js build tool similar to Grunt). However, I continuously get a "command not found" error.

Surely this is a bash/path/environment variables problem, I suspect. However, I am completely lost.

Can someone please advise what I may be doing incorrectly here? Your help is greatly appreciated.

If it's relevant: I also run zsh on my Webfaction environment

asked 29 Dec '14, 07:25

chrisbalt
1314
accept rate: 0%


Figure out where the executables were installed, and then either add that location to your PATH environment variable, or use the full path to the executable when you run it.

permanent link

answered 29 Dec '14, 20:25

seanf
12.2k31836
accept rate: 37%

Adding a NODE_PATH environment variable to always reference the current directory's "node_modules" folder worked, also: export NODE_PATH="$PWD/node_modules:$NODE_PATH"

(30 Dec '14, 03:37) chrisbalt
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×67
×23
×19

question asked: 29 Dec '14, 07:25

question was seen: 3,064 times

last updated: 30 Dec '14, 03:37

WEBFACTION
REACH US
SUPPORT
AFFILIATE PROGRAM
LEGAL
© COPYRIGHT 2003-2019 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM