adan#adan-HP-1000-Notebook-PC:~/wpscan$ sudo gem install bundler && bundle install --without test
Fetching: bundler-1.15.1.gem (100%)
Successfully installed bundler-1.15.1
Parsing documentation for bundler-1.15.1
Installing ri documentation for bundler-1.15.1
Done installing documentation for bundler after 10 seconds
1 gem installed
There was an error while trying to write to /home/adan/wpscan/.bundle/config.
It is likely that you need to grant write permissions for that path.
i don't know why, this problem always follow me
First of all: never install gems with sudo. To fix this for the future try uninstalling all gems / ruby, install rvm or rbenv them create a gemset for specific project and then install gems with bundle install. This error will most likely follow You a while if You don't repair it.
sudo gem install bundler && sudo bundle install
This probably would help, just for now.
Related
I am trying to run "bundle update", but I keep getting the error message:
An error occurred while installing rack (2.0.1), and Bundler cannot continue.
Make sure that `gem install rack -v '2.0.1'` succeeds before bundling.
Then I install rack 2.0.1:
sudo gem install rack -v 2.0.1
Successfully installed rack-2.0.1
Parsing documentation for rack-2.0.1
Done installing documentation for rack after 2 seconds
1 gem installed
Then I even ran "rbenv rehash", and I run "bundle update" again and the same error message shows up. How do I get Bundler to recognize the new gem?
Make sure you have the "bundler" installed from the ruby version installed by rbenv first. Then, check the ruby version in that directory. It should be the one that you installed from rbenv or rvm. After these, if you are installing something just don't use sudo before bundle. Because bundle is from the rbenv ruby version. If the rbenv rehash doesn't work, just restart the bash and check.
If the without sudo thing needs permission, you are most likely using the bundler that was installed by your system ruby as sudo gem install bundler.
Try reinstalling bundler without a sudo like gem install bundler and retry.
Even if that doesn't work, remove the Gemfile.lock in your directory. Remove any version of rack mentioned in your Gemfile if any. Just have the gem name like gem 'rack' and try bundle install again. The gem that you could install with sudo was stored for the system ruby, not the one you have installed through rbenv.
When you ran sudo install, your gem most probably got installed under a different directory. When using Rbenv or VRM, you shouldn't use sudo.
First of all you could try uninstalling the gem from your system gems and doing it again without sudo.
Going into extremes you could completely reinstall your rbenv with gems (and while at it switch to RVM, personally I think its easier to manage). After that try to bundle install everything again without sudo and it should work.
I've seen this question asked and tried everything I've seen suggested.
I got a new macbook and am looking to set up an existing app. When i clone the app, it will not bundle install and acts like Rails is not installed, even though it works in other directories.
I tried removing version numbers from gemfile and deleting gemfile.lock. I tried bundle update. I'm on osx 10.9.4, rails 4.1.5 and ruby 2.1.1.
the error I am getting:
An error occurred while installing nokogiri (1.6.3.1), and Bundler cannot
continue.
Make sure that `gem install nokogiri -v '1.6.3.1'` succeeds before bundling.
I have rvm installed. I tried reinstalling homebrew, rails and ruby.
What could it be?
Ok, phew. This worked:
http://jasdeep.ca/2013/10/installing-nokogiri-fails-os-x-mavericks/
xcode-select --install
gem install nokogiri
bundle config build.nokogiri --use-system-libraries
bundle install
then, the pg gem wouldnt let bundle install. this fixed it - Installing PG gem on OS X - failure to build native extension
brew update
brew install postgresql
gem install pg
then... bundle install worked, finally, but rails s was giving me an error, which this fixed: Devise Secret Key was not set
just had to add the line w/the secret key to the config/initializers/devise.rb right before the last 'end'
hope this helps anyone who upgrades to Mavericks / gets a new computer that comes with it installed!
First try to do this sudo apt-get install build-essential patch ruby-dev zlib1g-dev liblzma-dev, then try to install
I am a newbie when it comes to working with gems so pardon me if i'm getting my facts wrong.
I want to update Bundler from v1.3.5 to the latest version (v1.5.3) so I tried doing:
sudo gem install bundler --pre
the command line outputs:
Fetching: bundler-1.5.3.gem (100%)Fetching: bundler-1.5.3.gem
Successfully installed bundler-1.5.3
Parsing documentation for bundler-1.5.3
Installing ri documentation for bundler-1.5.3
Done installing documentation for bundler after 4 seconds
1 gem installed
but when I do gem list or bundle --version, it shows that i'm still using the old version (v1.3.5). This goes to all my other gems. I tried updating Susy, Sass and Compass the same way, but it doesn't get updated even though it says that it was installed successfully.
Any ideas? TIA
Fixed it. It seems that if you add sudo when installing gems, it installs the gem on a different directory from the one used when you don't use sudo. I saw this when I did sudo gem list and it displayed different results from a normal gem list command.
To be able to add gems without sudo I just did chown -R [current_user] [ruby_directory]
Run bundle update on the command line. This will update your gems in your app.
while i was trying to run this code "bundle install --without production"
I am getting an error like
"The program 'bundle' is currently not installed. You can install it by typing:
sudo apt-get install ruby-bundler
"
I have installed bundle already but still getting this error.
This problem occurred while i was learning from Harlt's.."Updating Gemfile" at Heroku setup section
First Set up the PATH variable for the installed ruby executable(Suppose the installed ruby is ruby-2.0.0-p451):
PATH=$PATH:$HOME/.rvm/gems/ruby-2.0.0-p451/bin
and then run,
gem install bundler (if bundler is not installed)
and lastly run,
rvm use ruby-2.0.0-p451 --default (--default is optional).
There you go. Now you would be able to run bundle command with out any issues.
Hope it helps :)
For those, who uses rbenv receipt is:
gem install bundler
rbenv rehash
bundle
hi all i am getting problem while installing rails in by gem :
i have written in terminal
gem install rails
Successfully installed rails-3.0.3
1 gem installed
Installing ri documentation for rails-3.0.3...
File not found: lib
what i need to do next and how to install rails using gem.
I had the same problem. I continued with the error. I do not see anything breaking. And I can code peacefully. So, probably you do not need to worry.
sudo apt-get install build-essential libopenssl-ruby libfcgi-dev
sudo apt-get install ruby irb rubygems ruby1.8-dev
sudo apt-get install sqlite3 libsqlite3-dev
sudo gem install rails
sudo gem install sqlite3-ruby
If you dont find path do this: (for Unix based systems)
Quoted from the book, but anyone else would suggest the same
If you can’t find the rails command, you may need to add
/var/lib/gems/1.8/bin to your PATH environment variable.
You can do this by adding a line to your .bashrc file:
export PATH=/var/lib/gems/1.8/bin:$PATH
OK as aditya sanghi has mentioned, I do lack rdoc gem-- so probably running this will help
gem install rdoc rails
I've seen this error when you dont have the "rdoc" gem installed. Can you do a "gem list" and show us a list of gems installed?
Try running "gem install rdoc rails".