I am trying to install the github-pages gem on Ubuntu 14.04.
I get this error about the version of a dependency (with or without sudo doesn't change the outcome):
$ sudo gem2.0 install github-pages
ERROR: While executing gem ... (Gem::DependencyError)
Unable to resolve dependencies: github-pages-health-check requires public_suffix (~> 1.4)
However, doing gem2.0 list --local shows me:
public_suffix (2.0.4)
What's the problem here? I have 2 coexisting versions of ruby (ruby1.9.3 and ruby2.0), but I have made /usr/bin/ruby link to ruby2.0.
~> is a pessimistic version constraint. ~> 1.4 means >= 1.4 and < 2.0, and your version of public_suffix is not in that range. Try
gem install public_suffix -v 1.5.3
which is the newest version that actually satisfies the constraint.
Related
Bundler could not find compatible versions for gem "bundler":
In Gemfile:
rails (~> 5.2) was resolved to 5.2.3, which depends on
bundler (>= 1.3.0)
solargraph was resolved to 0.38.0, which depends on
bundler (>= 1.17.2)
Current Bundler version:
bundler (1.16.2)
This Gemfile requires a different version of Bundler.
Perhaps you need to update Bundler by running `gem install bundler`?
Could not find gem 'bundler (>= 1.17.2)', which is required by gem 'rails (~> 5.2)', in any of the sources.
ERROR: 6
I am using ruby version 2.5.1 on my device and rvm is not installed earlier the version of ruby 3.0.2 but our project is of version 2.5.1. But while installing any new gem and hitting bundle install it shows this particular error
sudo docker-compose run --rm --no-deps web bundle install
I got following error for bundle
Bundler could not find compatible versions for gem "bundler": In
Gemfile:
bundler (~> 1.15)
Current Bundler version:
bundler (2.0.1) This Gemfile requires a different version of Bundler. Perhaps you need to update Bundler by running gem install
bundler?
Could not find gem 'bundler (~> 1.15)' in any of the relevant sources:
the local ruby installation
then I tried to downgrade the bundler version with
$ gem install bundler -v '~> 1.7.0' Fetching: bundler-1.7.15.gem
(100%) Successfully installed bundler-1.7.15 Parsing documentation for
bundler-1.7.15 Installing ri documentation for bundler-1.7.15 Done
installing documentation for bundler after 1 seconds 1 gem installed
but when I recheck the bundler version with
bundler --version
it still said Bundler version 2.0.1
The default bundler version on your system is still 2.0.1. If you need to use the downloaded version 1.7.15, you would have to run bundle _1.7.15_ install. You could also check if that version was successfully installed on your system using bundle _1.7.15_ -v
In either case, if you get the error Could not find command "_1.7.15_", then that means that the bundler version _1.7.15_ has not been installed on your system.
Additionally, these links may help you:
Run specific version of bundler
Downgrade Bundler in RVM
Try updating bundle with bundler update bundler and run the bundle update again. It solved my problem the last time.
I got a problem when i was installing Jekyll on win10.
When I finished deployment for ruby and wanna install Jekyll, it needs to install bundle first.
Fetching ffi 1.9.17 (x64-mingw32)
Installing ffi 1.9.17 (x64-mingw32)
Gem::RuntimeRequirementNotMetError: ffi requires Ruby version < 2.5, >= 2.0. The
current ruby version is 2.5.0.
An error occurred while installing ffi (1.9.17), and Bundler cannot continue.
Make sure that `gem install ffi -v '1.9.17'` succeeds before bundling.
Then I followed the instruction
gem install ffi -v 1.9.17
The Error log is
ERROR: Error installing ffi:
The last version of ffi (= 1.9.17) to support your Ruby & RubyGems was 1.9.17. Try installing it with `gem install ffi -v 1.9.17`
ffi requires Ruby version < 2.5, >= 2.0. The current ruby version is 2.5.0.
Also I have tried to followed the solution by vbortone.
gem install ffi -f
It also didn't work.
ERROR: Error installing ffi:
The last version of ffi (= 1.9.17) to support your Ruby & RubyGems was 1.9.17. Try installing it with `gem install ffi -v 1.9.17`
ffi requires Ruby version < 2.5, >= 2.0. The current ruby version is 2.5.0.
The recent versions of ffi installs fine on Ruby 2.5. Bundler automatically requests for the latest version, unless there's a Gemfile.lock file, or a constraint has been specified in a Gemfile file or a dependency's gemspec.
You can first try running bundle update.
If that doesn't work, you can edit the Gemfile file (if available), and add gem 'ffi', '~> 1.9' before running bundle install. You can also manually install the gem with gem install ffi.
I've successfully generated file tree via calabash-android gen
After that I've tried to run tests:
calabash-android run ../app/build/outputs/apk/app-debug.apk
But got error:
Unable to activate calabash-android-0.9.0, because json-2.0.2 conflicts with json (~> 1.8) (Gem::ConflictError)
I've installed json 1.8.6 via gem install 'json' -v 1.8.6
and now gem list json outputs me
*** LOCAL GEMS ***
json (default: 2.0.2, 1.8.6)
multi_json (1.12.1)
But error Unable to activate calabash-android-0.9.0, because json-2.0.2 conflicts with json (~> 1.8) (Gem::ConflictError) throwed again. Where I am wrong?
UPD
I've tried to solve problem as described here github.com/calabash/calabash-ios/issues/1260 but osx says that I cant remove 2.0.2 version because it's default
MacBook-Pro-MacBook:calabash zub3r$ gem uninstall -Vax --force --no-abort-on-dependent json
ERROR: While executing gem ... (Gem::InstallError)
json is not installed in GEM_HOME, try:
gem uninstall -i /Users/zub3r/.rvm/gems/ruby-2.4.0#global json
MacBook-Pro-MacBook:calabash zub3r$ gem uninstall -i /Users/zub3r/.rvm/gems/ruby-2.4.0#global json
You have requested to uninstall the gem:
json-1.8.6
calabash-android-0.9.0 depends on json (~> 1.8)
cucumber-1.3.20 depends on json (~> 1.7, development)
luffa-2.0.0 depends on json (~> 1.8)
If you remove this gem, these dependencies will not be met.
Continue with Uninstall? [yN] ^CERROR: Interrupted
MacBook-Pro-MacBook:calabash zub3r$ gem uninstall -i /Users/zub3r/.rvm/gems/ruby-2.4.0#global json --version 2.0.2
ERROR: While executing gem ... (Gem::InstallError)
gem "json" cannot be uninstalled because it is a default gem
Problem solved by using bundler
bundle init
Gemfile content replaced with
# frozen_string_literal: true
source "https://rubygems.org"
gem 'calabash-android'
then
bundle install
I was facing same issue,I had downgraded my ruby version and it got solved.
Please find the solution below
$ gem -v
2.0.3
$ gem list rubygems-update
$ gem uninstall -v 2.0.3 rubygems-update
$ gem install -v 1.8.24 rubygems-update
$ update_rubygems
$ gem -v
1.8.24
I am following the instructions here: https://help.github.com/articles/setting-up-your-github-pages-site-locally-with-jekyll/ to set up Jekyll with Guthub on Ubuntu 14.04 and I'm running into a problem when I try to run "bundle install". Here's the output I get:
Fetching gem metadata from https://rubygems.org/
Fetching version metadata from https://rubygems.org/
Fetching dependency metadata from https://rubygems.org/
Rubygems 1.8.23 is not threadsafe, so your gems will be installed one at a time. Upgrade to Rubygems 2.1.0 or higher to enable parallel gem installation.
Your user account isn't allowed to install to the system Rubygems.
You can cancel this installation and run:
bundle install --path vendor/bundle
to install the gems into ./vendor/bundle/, or you can enter your password
and install the bundled gems to Rubygems using sudo.
Password:
Installing RedCloth 4.2.9 with native extensions
Using i18n 0.7.0
Using json 1.8.3
Installing minitest 5.8.3
Using thread_safe 0.3.5
Using addressable 2.4.0
Installing blankslate 2.1.2.4
Installing fast-stemmer 1.0.2 with native extensions
Using coffee-script-source 1.10.0
Using execjs 2.7.0
Using colorator 0.1
Using ffi 1.9.10
Using multipart-post 2.0.0
Using gemoji 2.1.0
Using net-dns 0.8.0
Installing public_suffix 1.5.3
Gem::InstallError: public_suffix requires Ruby version >= 2.0.
Using jekyll-paginate 1.1.0
Using sass 3.4.22
Using rb-fsevent 0.9.7
Installing kramdown 1.5.0
Installing liquid 2.6.1
Using mercenary 0.3.6
Installing posix-spawn 0.3.11 with native extensions
Installing yajl-ruby 1.2.1 with native extensions
Installing redcarpet 3.1.2 with native extensions
Using safe_yaml 1.0.4
Using mini_portile2 2.1.0
Using pkg-config 1.1.7
Installing jekyll-sitemap 0.6.3
Installing maruku 0.7.0
Installing rdiscount 2.1.7 with native extensions
Using terminal-table 1.6.0
Using bundler 1.12.5
Using tzinfo 1.2.2
Installing parslet 1.5.0
Installing classifier-reborn 2.0.4
Using coffee-script 2.4.1
Using ethon 0.9.0
Using rb-inotify 0.9.7
Using faraday 0.9.2
An error occurred while installing public_suffix (1.5.3), and Bundler cannot continue.
Make sure that `gem install public_suffix -v '1.5.3'` succeeds before bundling.
When I run "sudo gem install public_suffix -v '1.5.3'" I get:
Successfully installed public_suffix-1.5.3
Parsing documentation for public_suffix-1.5.3
Done installing documentation for public_suffix after 0 seconds
1 gem installed
When I run "ruby --version" I get:
ruby 2.3.1p112 (2016-04-26 revision 54768) [x86_64-linux]
Any idea what to try next?