OK, I'm trying to figure out how to get a gem install that the install script fails due to a space in the path name. I've tried everything I could, but for some reason the bundle install still picks up the long path rather than the symlinked path I have without the spaces.
Where does it pick up these paths?
I've tried updating bundle config but it still list the long path as the path to the local app rather than the new symlink path. If I update, it only does it for the local user not the local app.
I am stuck and I've crashed my machine by trying to remove the space in the volume name, I've added all the environment variables I can think of, I'm at a loss to get the bundler to install without referencing the path with a space in it.
I've tried contacting the developers for the gem, no love. I just need to get the whole app to use the symlink path rather than the /Volumes/Macintosh HD/ path. Ideas? suggestions? crazy ideas? I'm willing to give anything a shot at this point.
Update 12/16:
Gem is FFI.
Here's the Gemfile:
source 'http://rubygems.org'
require 'rubygems'
gem 'rails', '3.0.8'
gem 'jquery-rails'
gem 'haml'
gem 'devise'
gem 'omniauth-openid'
gem 'omniauth-twitter'
gem 'omniauth-facebook'
gem 'omniauth-github'
gem "settingslogic"
gem 'composite_primary_keys'
# Bundle edge Rails instead:
# gem 'rails', :git => 'git://github.com/rails/rails.git'
gem 'pg'
gem 'squeel'
gem 'sqlite-ruby'
gem 'mysql2', '~> 0.2.6'
gem "bcrypt-ruby", :require => "bcrypt"
group :development, :test do
gem 'rspec-rails'
gem 'ruby-debug19', :require => 'ruby-debug'
gem 'hpricot', :require => false #html2haml
gem 'ruby_parser', :require => false # html2haml
gem 'pickle'
gem 'awesome_print', :require => 'ap'
gem 'factory_girl_rails'
end
group :development do
gem 'heroku', :require => false
gem 'sass'
end
group :test do
gem 'shoulda'
gem 'cucumber-rails'
gem 'spork', '~> 0.9.0.rc3'
gem 'guard-spork'
gem 'database_cleaner'
end
Install rvm
Create a gemset
Add a .rvmrc file to your RAILS_ROOT directory.
cd into your RAILS_ROOT directory.
Run bundle install.
I just removed the space in the volume name, I tried fixing the install script but I'd fix one area and it would error out in another.
Related
I just did a fresh install of mavricks, Postgres.app, RVM, Git.
I created a standard new rails app and everything worked fine.
However when I tried to grab a project from github and can not get bundle install to run.
d3 git:(master) bundle install
Fetching gem metadata from https://rubygems.org/.......
Fetching gem metadata from https://rubygems.org/..
Updating git://github.com/thomas-mcdonald/bootstrap-sass.git
fatal: Could not parse object '9c6c07f74ff515cf38380b014cfede14a4f0eae4'.
Git error: command `git reset --hard 9c6c07f74ff515cf38380b014cfede14a4f0eae4`
in directory
/Users/tyler/.rvm/gems/ruby-1.9.3-p448#d3/bundler/gems/bootstrap-sass-9c6c07f74ff5
has failed.
If this error persists you could try removing the cache directory
'/Users/tyler/.rvm/gems/ruby-1.9.3-p448#d3/cache/bundler/git/bootstrap-sass-33efd1d8ffb6176fdb805029a30f02a6edfbae2e'
I tried to remove the project and clone it again.
I tried removing the gemset and removing all the gems from the gemset.
I also tried to follow the error message and remove the cache folder.
Please help I really need to get back to working on this project.
Update:
I just tried a bundle update as well.
➜ d3 git:(master) bundle update
Updating git://github.com/thomas-mcdonald/bootstrap-sass.git
fatal: ambiguous argument '3': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
Git error: command `git rev-parse 3` in directory
/Users/tyler/.rvm/gems/ruby-1.9.3-p448#d3/cache/bundler/git/bootstrap-sass-33efd1d8ffb6176fdb805029a30f02a6edfbae2e
has failed.
If this error persists you could try removing the cache directory
'/Users/tyler/.rvm/gems/ruby-1.9.3-p448#d3/cache/bundler/git/bootstrap-sass-33efd1d8ffb6176fdb805029a30f02a6edfbae2e'
Update
source 'https://rubygems.org'
ruby '1.9.3'
gem 'rails', '3.2.15'
# Bundle edge Rails instead:
# gem 'rails', :git => 'git://github.com/rails/rails.git'
gem 'pg'
gem 'thin'
gem 'unicorn'
gem 'newrelic_rpm'
gem 'mixpanel-ruby'
# Gems used only for assets and not required
# in production environments by default.
gem 'sass-rails', '~> 3.2.3'
gem 'coffee-rails', '~> 3.2.1'
gem 'uglifier', '>= 1.0.3'
gem 'jquery-rails'
gem 'bootstrap-sass', :git => 'git://github.com/thomas-mcdonald/bootstrap-sass.git', :branch => '3'
gem "font-awesome-rails"
gem 'haml_coffee_assets'
gem 'execjs'
group :development, :test do
gem 'jasmine-rails'
gem "letter_opener"
gem 'pry-rails'
gem 'rspec-rails'
gem 'capybara'
gem 'spin'
end
gem 'active_link_to'
gem 'acts_as_list'
gem "aws-sdk"
gem 'backbone-on-rails'
gem 'browser'
gem 'devise'
gem 'gon'
gem 'js-routes'
gem 'oj'
gem 'pusher'
gem 'rabl'
gem 'simple_form'
There is no branch 3 in https://github.com/thomas-mcdonald/bootstrap-sass/ anymore. That's why Git is complaining. So you need to change it from:
gem 'bootstrap-sass', :github => 'git://github.com/thomas-mcdonald/bootstrap-sass.git', :branch => '3'
to:
gem 'bootstrap-sass', :git => 'git://github.com/thomas-mcdonald/bootstrap-sass.git'
or use a shorthand syntax:
gem 'bootstrap-sass', :github => 'thomas-mcdonald/bootstrap-sass'
When running autotest, I get the error Could not find ZenTest-4.7.0 in any of the sources. After viewing this article, I deleted gemfile.lock, ran 'bundle install', and then tried rerunning autotest. Now I get the error Could not find rake-10.0.3 in any of the sources. FYI, I am using RBENV, and I have no other problems running my app (rails c, rails s, rake, ...). Here is my gem file (btw, both "missing" files appeared in gemfile.lock):
source 'http://rubygems.org'
gem 'rails', '3.1.3'
gem 'rake'
gem 'pg', '0.13.2'
# Sidekiq handles background jobs, using threading
gem 'sidekiq', '>= 2.6.1'
# Need the following gems for sidekiq/web
gem 'slim'
# if you require 'sinatra' you get the DSL extended to Object
gem 'sinatra', :require => nil
gem 'heroku-api' # Need the API for scaling sidekiq
gem 'json'
gem 'premailer'
# Gems used only for assets and not required
# in production environments by default.
group :assets do
gem 'sass-rails', '3.1.4'
gem 'coffee-rails', '~> 3.1.1'
gem 'uglifier', '>= 1.0.3'
end
gem 'jquery-rails'
# To use ActiveModel has_secure_password
gem 'bcrypt-ruby', '~> 3.0.0'
# Use unicorn as the web server
# gem 'unicorn'
# Deploy with Capistrano
# gem 'capistrano'
# Bundle the extra gems:
gem 'mechanize'
gem 'nokogiri'
gem 'spreadsheet'
gem 'xml-simple'
gem 'faker', '~> 0.3.1'
# Bundle gems for the local environment. Make sure to
# put test-only gems in this group so their generators
# and rake tasks are available in development mode:
group :development do
gem 'rspec-rails'
gem 'ruby-debug19'
end
group :test do
gem 'rspec-rails'
gem 'ZenTest'
gem 'shoulda-matchers'
gem 'webrat', '0.7.1'
gem 'factory_girl_rails'
gem 'ruby-debug19'
end
gem 'geoip'
gem 'thin'
gem 'htmlentities'
I'm not 100% certain, but I think you just do:
gem install ZenTest
and probably
gem install autotest-rails
From within your application directory.
These guys are not managed by your gemfile and bundler
I am using ubuntu and rvm 1.8.6, ruby 1.9.2, bundler (1.1.rc, 1.0.21), it was working ok. But recently, I cleared my gemset and run bundle install again to get freshen up because some stupid things I did on my own.
But the bundler puts all the gems under ./libv8 folder inside my project folder, it's quite weird to me. And my rvm folder is getting nothing. Is it because of the "therubyracer"? The following is my gemfile:
gem 'rails'
gem 'rspec'
gem 'rake', '>=0.9.2'
gem 'mongoid'
gem 'bson_ext'
gem 'hpricot'
gem 'jquery-rails', '>= 1.0.12'
gem 'therubyracer'
gem "bcrypt-ruby", :require => "bcrypt"
gem 'gdata'
#gem 'SystemTimer', '1.2.3'
# Gems used only for assets and not required
# in production environments by default.
group :assets do
gem 'sass-rails', " ~> 3.1.0"
gem 'coffee-rails', "~> 3.1.0"
gem 'uglifier'
end
group :test do
# Pretty printed test output
gem 'turn', :require => false
end
Take a look at the .bundle/config file in your app's root.
Check if the BUNDLE_PATH variable is set, and in case it is, delete it.
Bundler will go back to rubygem's default behaviour, which is installing gems in $GEM_HOME.
You probably executed bundle install --path ./libv8 once and forgot about it.
This is first time I'm trying to use Omniauth. While I was testing https://github.com/pt/devise-omniauth-example this example from github I came across an error
.rvm/gems/ruby-1.9.2-p290/gems/activesupport-3.1.3/lib/active_support/dependencies.rb:240:in `require': no such file to load -- openid/store/filesystem (LoadError)
Here is my Gemfile content
source 'http://rubygems.org'
gem 'rake'
gem 'rails'
gem 'sqlite3-ruby', :require => 'sqlite3'
gem 'devise', :git => 'git://github.com/plataformatec/devise', :branch => 'master'
gem "omniauth", "1.0.1"
gem 'paperclip'
gem "simple_form", "~> 1.5.2"
gem 'twitter_oauth', '0.4.3'
gem "rest-client", "1.6.7", :require => "restclient"
gem "sluggable"
group :development, :test do
gem 'rspec-rails'
gem 'fixjour'
end
I search web but there was no luck.
According to this:
If you get "openid/store/filesystem (LoadError)" then you may need to add this to your Gemfile:
gem "oa-openid"
This is due to various versions of Gems you are using and the dependencies among them.
In the example at https://github.com/pt/devise-omniauth-example,
if you notice the Gemfile ,there is
gem 'omniauth', '0.2.0'
but in your Gemfile above, you are using
gem "omniauth", "1.0.1"
Add gem 'ruby-openid-apps-discovery', and add below in application.rb.
require 'omniauth-openid'
require 'openid'
require 'openid/store/filesystem'
require 'gapps_openid'
My Gem file looks like this:
source 'http://rubygems.org'
gem 'rails', '3.0.0'
# Bundle edge Rails instead:
# gem 'rails', :git => 'git://github.com/rails/rails.git'
#gem 'sqlite3-ruby', :require => 'sqlite3'
gem 'sqlite3-ruby', '1.2.5', :require => 'sqlite3'
group :development do
gem 'rspec-rails', '2.0.0.beta.18'
end
group :test do
gem 'rspec', '2.0.0.beta.18'
end
# Use unicorn as the web server
# gem 'unicorn'
# Deploy with Capistrano
# gem 'capistrano'
# To use debugger
# gem 'ruby-debug'
# Bundle the extra gems:
# gem 'bj'
# gem 'nokogiri'
# gem 'sqlite3-ruby', :require => 'sqlite3'
# gem 'aws-s3', :require => 'aws/s3'
# Bundle gems for the local environment. Make sure to
# put test-only gems in this group so their generators
# and rake tasks are available in development mode:
# group :development, :test do
# gem 'webrat'
# end
I get that error message when I try to go to /pages/home.
I am following the railstutorial guide and am at this point: http://railstutorial.org/chapters/static-pages#code:pages_routes
Btw, I am using sqlite3 as my db for now - if you were wondering.
Any ideas?
Edit: When I load the page, I am seeing a windows error message that says "ruby.exe - Entry point not found: The procedure entry point rb_str2cstr could not be located in the dynamic link library msvcrt-ruby191.dll".
Then it shows the error message in the browser.
I just had this issue on a windows vista system and got it working by downloading the precompiled binaries for windows from the sqlite website:
http://sqlite.org/download.html
once I downloaded the shell and the dll (I would have posted the links directly but this site will only allow me to post 1!!!) to my desktop I extracted them to the C:\Ruby192\bin folder and then ran:
gem install sqlite3-ruby
from the command line.
My issue is now fully resolved. Hope that helps.
I fixed this by re-creating my app, and in the initial bundle install, I changed the gem file to just have:
gem 'sqlite3-ruby', :require => 'sqlite3'
and not:
gem 'sqlite3-ruby', '1.2.5', :require => 'sqlite3'
This seems to work. For whatever reason, that version of sqlite3 was not agreeing with my setup.