Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"command not found : coffee" error when running rake #3

Open
bigfish opened this issue Mar 22, 2013 · 14 comments
Open

"command not found : coffee" error when running rake #3

bigfish opened this issue Mar 22, 2013 · 14 comments

Comments

@bigfish
Copy link

bigfish commented Mar 22, 2013

I just cloned the repo, did 'bundle install' and 'npm install' but when I try to build the .js files, I get the error:

bundler: command not found: coffee
Install missing gem executables with bundle install

Any idea what I'm doing wrong, or is this a bug?

Using Ubuntu 12.04, ruby 1.9.3 (RVM) and gem 1.8.24

@JamesMaroney
Copy link
Contributor

When in the Isolate directory, what do you get when you do a bundle list?

@bigfish
Copy link
Author

bigfish commented Mar 22, 2013

  • bundler (1.3.0)
  • coffee-script (2.2.0)
  • coffee-script-source (1.3.3)
  • execjs (1.4.0)
  • guard (1.4.0)
  • guard-coffeescript (1.2.0)
  • listen (0.5.2)
  • multi_json (1.3.6)
  • rb-fsevent (0.9.1)
  • ruby_gntp (0.3.4)
  • thor (0.16.0)

@JamesMaroney
Copy link
Contributor

Interesting. The Rakefile executes bundle exec coffee --compile --output . src/isolate.coffee though you do have the coffee-script gem installed. What happens if you try bundle exec coffee --version ?

@bigfish
Copy link
Author

bigfish commented Mar 22, 2013

I get the same error

bundle exec coffee --version

bundler: command not found: coffee
Install missing gem executables with bundle install

@bigfish
Copy link
Author

bigfish commented Mar 22, 2013

Bundler version 1.3.4

@JamesMaroney
Copy link
Contributor

@brendanjerwin any ideas on what might be amiss here? I'm drawing a blank.

@jacebennett
Copy link

I can reproduce this on Ubuntu 13.04 without rvm and the latest everything else. Checking it out.

Gems included by the bundle:
  * bundler (1.3.4)
  * coffee-script (2.2.0)
  * coffee-script-source (1.3.3)
  * execjs (1.4.0)
  * guard (1.4.0)
  * guard-coffeescript (1.2.0)
  * listen (0.5.2)
  * multi_json (1.3.6)
  * rb-fsevent (0.9.1)
  * ruby_gntp (0.3.4)
  * thor (0.16.0)

@jacebennett
Copy link

So the gem no longer provides an executable (I think I knew that once). We have to use the node module.

npm install -g coffee-script would work presumably.

running export PATH="./node_modules/.bin:$PATH" fixes it in my environment, and http://stackoverflow.com/questions/9679932/how-to-use-package-installed-locally-in-node-modules seems to suggest this is the preferred solution. I don't particularly like it myself.

We could update the Rakefile to explicitly call the one in the node_modules/.bin, I suppose. Thoughts?

@jacebennett
Copy link

This works in bash, but my rake-fu is weak.

`npm bin`/coffee

@jacebennett
Copy link

@bigfish Can you check it out in the branch for #4? I want to make sure this works in windows (it probably won't) before I pull it in, but I don't have that environment handy atm.

@JamesMaroney
Copy link
Contributor

Ah, thanks Jace, good find. If this works out we can get the rakefile
updated tonight.

@bigfish
Copy link
Author

bigfish commented Mar 23, 2013

I checked out the npm-path-for-rake-tasks branch and I was able to run rake successfully to compile isolate.js. This was on my home Ubuntu box running 12.10 but otherwise pretty much the same as previously mentioned... node 0.8 ruby 1.9.3 (from RVM). It still has the same issue on the master branch so I'd say this fixes the problem. Thanks for dealing with this so quickly.

I noticed there's also an npm package version of this.. is this only for use in node?

@JamesMaroney
Copy link
Contributor

We use this to test require-js based AMD modules for the browser (though we
run the tests in node)
There has also been some success using this to help in testing common-js
modules.

I'll merge this into master after doing some more testing.

Let us know if you hit any more issues using Isolate!

@pegasuspect
Copy link

Thanks @bnwasteland =)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants