Unable to generate friendly_id from gem - ruby-on-rails

I'm trying to use Friendly ID to handle slugs in my Rails app. When I run "rails generate friendly_id", I get the following error:
/usr/lib/ruby/gems/1.8/gems/activesupport-3.0.3/lib/active_support/dependencies.rb:239:in `require': no such file to load -- babosa (LoadError)
However, the babosa gem is definitely installed.
How can I even begin to solve this?

I was able to fix the problem by installing Bundler and adding the following lines to "Gemfile" in the root of my app:
gem 'babosa'
gem 'friendly_id'

I've not seen this problem myself, but have you tried the Google Group for the gem? It looks like that's the author's preferred communication method, and he looks to be fairly responsive there.
http://groups.google.com/group/friendly_id

Related

cannot load such file -- mongo_mapper/document

I am receiving the following error message when attempting to authenticate with Facebook in a rails app using MongoMapper:
It appears that MongoMapper is not being loaded properly, but I am not sure why. In my Gemfile I include gem 'mongo_mapper, gem 'bson_ext', and gem 'omniauth-facebook', '~> 1.4.1'. I also followed the setup instructions here: http://mongomapper.com/documentation/getting-started/rails.html to completion. I am able to run the $ mmconsole, as well as connect to the mongod using the $ mongo. Is there another configuration step that I missing to ensure that mongo_mapper can be loaded properly? Thanks in advance for any assistance, I am new to MongoDB in general.
EDIT:
Here is what my SessionsController looks like, where the LoadError originates:

Rails and outside libraries

I am trying to use this gem in my rails application, but when I add it to my gem file and try to use it I get an error saying that it did not found the methods required (I am using it inside a controller). Also require 'bn4r' does not help as rails tells me that it cannot load such a file, which is odd. I can access the library from the development console with no problems any idea as to why this happens?
After adding the gem to the Gemfile:
gem 'bn4r'
install it:
$ bundle install
Restart the server and use it like this:
BayesNet.new

EventCalendar table bulider is not installing in rails 4

I am having problem in full_calendar table builder.and i am using rails 4.I have used following command . **rails plugin install git://github.com/p8/table_builder.git
** I got error like **/usr/local/rvm/gems/ruby-2.0.0-p247#ruby2/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:228:in `require': cannot load such file -- rails/commands/plugin (LoadError)
**
And My view look like
It won't showing in table format. Please help me....
Use the gem instead of the plugin. Also I don't think that repository is active anymore, there is an alternative listed on the readme; and it doesn't look like table_builder has been updated for rails 4 so you might encounter other issues.
This is the updated repo: https://github.com/watu/table_builder
Add it to your gemfile & run bundle install:
gem "watu_table_builder", :require => "table_builder"
If you're using a tutorial for an older version of rails note that there are some things that will bite you -- (plugins, strong paramenters, Model.all, etc)

Does a Rails 3.0.0.beta app only see bundled gems in the console?

I have a library that I'm trying to get working with rails 3 (specifically feedzirra) which I can require ok in irb but it breaks the console in my app with the following error:
http://pastie.org/855976
Found a bit of info on using feedzirra with rails 3. It looks like your problem might be with the Loofah library feedzira uses. It uses the deprecated config.framework.
Here's a link with some more info http://www.mythoughtpot.com/2010/02/10/feedzirra-on-rails3/
Rails3 modifies the $LOAD_PATH so it only contains gems listed in the Gemfile.
($LOAD_PATH is an array of directories where Ruby searches for libraries).
So you must add the Gem to the Gemfile and run bundle install.
You can check if the gem is in your path by typing puts $LOAD_PATH.grep(/feedzirra/) in the rails console.
For more information on using Bundler in Rails3 check out these:
http://railsdispatch.com/posts/bundler
http://railscasts.com/episodes/201-bundler

Problem installing googlecharts gem?

I am trying to use the googlecharts gem to create some quick charts. Here are the rubyforge and github sites:
http://googlecharts.rubyforge.org/
http://github.com/mattetti/googlecharts/tree/master
After installing, I keep getting an error saying "no such file to load -- googlecharts" even though when I do a "gem list", the gem is listed. I have restarted my server. Anyone know what could be going on here?
Thanks!
According to the docs, you need to
require 'gchart'
but it sounds like you might be doing
require 'googlecharts'
instead.
You must do a gem install googlecharts first and then add gem "googlecharts" to your gemfile, then run bundle install. You should be free from the error afterwards.

Resources