Skip to content
This repository has been archived by the owner on Dec 24, 2020. It is now read-only.

Rails 3 Support #20

Open
soffes opened this issue Jan 2, 2010 · 7 comments
Open

Rails 3 Support #20

soffes opened this issue Jan 2, 2010 · 7 comments
Labels

Comments

@soffes
Copy link

soffes commented Jan 2, 2010

Currently, when you try to install more into a Rails 3 app, you get

Plugin not found: ["git://github.com/cloudhead/more.git"]

If you try to run script server, you get a NameError on the first request. Here's part of the stack:

/path/to/railsapp/vendor/plugins/more/rails/init.rb:3: undefined local variable or method `config' for main:Object (NameError)
    from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `gem_original_require'
    from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `require'
    from /path/to/railsapp/vendor/gems/dirs/rails/activesupport/lib/active_support/dependencies.rb:167:in `require'
    from /path/to/railsapp/vendor/gems/dirs/rails/activesupport/lib/active_support/dependencies.rb:537:in `new_constants_in'
    from /path/to/railsapp/vendor/gems/dirs/rails/activesupport/lib/active_support/dependencies.rb:167:in `require'
    from /path/to/railsapp/vendor/plugins/more/init.rb:1
  ...
@KieranP
Copy link

KieranP commented Feb 13, 2010

Additionally, treetop and polyglot are incompatible, and cause booting to fail completely, so patches will need to make it upstream to those projects before this plugin itself is compatible.

@augustl
Copy link
Contributor

augustl commented Feb 13, 2010

Odd, how can treetop and polygot affect Rails in any way?

@KieranP
Copy link

KieranP commented Feb 14, 2010

I didn't do deep investigations, but it looked like Polyglots redefine of Kernel#require had something to do with it.

@fortuity
Copy link

Fails with Rails 3 beta 4. Installed with "gem 'less'" in the Gemfile and ran "bundle install". Tried "rake more:generate" and got error "Don't know how to build task 'more:generate'".

@KieranP
Copy link

KieranP commented Jun 27, 2010

@fortuity: Have a look at less.js. I've got it working nicely with Rails 3 because it doesn't actually use Ruby, and it's very fast. http://github.com/cloudhead/less.js

@bjorntrondsen
Copy link

It seems to be working just fine in Rails 3.0.3 for me. All I did was:
Add "gem 'less'" to the gemfile
bundle install
rails plugin install git://github.com/cloudhead/more.git
Then I added a file to config/initializers for the configuration (for stuff like Less::More.source_path). This shouldnt be needed if you're fine with the default configuration.

@marioestrada
Copy link

Check this less-js gem for working with the JS version of Less: https://github.com/thisduck/ruby-less-js

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

No branches or pull requests

6 participants