Meet node.js faye issues (and fix)

14 views
Skip to first unread message

David

unread,
Nov 27, 2010, 3:45:20 PM11/27/10
to PeepCode
I had some troubles getting Faye up and running right when following
along with the screencast. Posted here in case anyone else has the
same issues I did.

This is for node 0.2.5 and Faye 0.5.3 (both updated since the
screencast was recorded).

It wasn't clear to me (because I didn't RTFM) that I needed to run
'jake' on the faye dir where I placed it in ./vendor/
To run the jake task you'll need the jake gem then run 'jake' (just
like running rake without any arguments). This wouldn't run for me
(command not found) and is something to do with RVM or my install of
RVM. I installed jake the non-RVM way (with sudo) and I could run the
command - except it didn't work.

Upon running 'jake' I got some cryptic error about stat and README
doesn't exist. There are a couple of lines in the Jakefile to do with
generating/updating the README and History files. Since I didn't care
too much about those files I removed the references and 'jake' finally
worked.

Running 'jake' creates some js files from yaml files and templates in
the faye project. It created a build dir and in there was the faye-
node.js file you need to require in livestats.js. My require statement
looked like
faye = require('faye-0.5.3/build/faye-node');

After those few steps/requirements it looks like everything is working
as it should.
Reply all
Reply to author
Forward
0 new messages