Error running Jekyll on OS X Yosemite 10.10.5 - ruby

I have a problem running Jekyll on OS X Yosemite 10.10.5. When I run jekyll serve, I get the following error:
MacBook-Pro-Svetlana:iloveip svetlana$ jekyll serve
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/dependency.rb:296:in `to_specs': Could not find 'jekyll' (>= 0) among 22 total gem(s) (Gem::LoadError)
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/dependency.rb:307:in `to_spec'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_gem.rb:47:in `gem'
from /usr/bin/jekyll:22:in `<main>'
MacBook-Pro-Svetlana:iloveip svetlana$
I had to reinstall OS X Yosemite. And I might have done something wrong. First, I installed Xcode Command Line Tools without actually installing Xcode. Then I followed instructions on this site to install Ruby and Git. After that I installed Jekyll but it wasn't running with jekyll serve. So I installed Xcode, but still got some errors.
So I upgraded RVM, and also upgraded Ruby to 2.2.3. After that I uninstalled and installed Jekyll once again. But when I try to run it I get the error above.
What can I do to fix it?

Hmmm. New problem seems that you have a problem with gem sources.
Re-generating sources can help.
$ gem sources --remove https://rubygems.org/
$ gem sources -a http://rubygems.org/
$ gem install jekyll
And now, install Jekyll again.

Related

Can't complie SCSS after updating to OS X 10.13

I've bee unsing Dreamweaver and Koara to compile scss files by compass.
But since I updated my Mac to OS X 10.3 (HighSierra) I got those error messages.
Users/MyAccount/Desktop/test/sass/mtnCommon.scss
/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/dependency.rb:319:in `to_specs': Could not find 'compass' (>= 0) among 15 total gem(s) (Gem::LoadError)
Checked in 'GEM_PATH=/Users/MyAccount/.gem/ruby/2.3.0:/Library/Ruby/Gems/2.3.0:/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/gems/2.3.0', execute `gem env` for more information
from /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/dependency.rb:328:in `to_spec'
from /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_gem.rb:65:in `gem'
from /Applications/Koala.app/Contents/Resources/app.nw/bin/compass:17:in `
'
Please let me know how to solve this.
Steps to fix this problem:
Open Terminal
Install Homebrew:

ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
Do not close Terminal. Open Mac Appstore and check Update, install all XCode Command Line Tools updates
Back to Terminal
Install Ruby:
brew install rbenv ruby-build
Install SASS gem:
sudo gem install sass
I've asked on GitHub's compass issue, and I got a reply saying "Fix this issue from DW side.".
So I need to wait until next DW comes out. Until then, I'll compile manually.
If you're using Koala, please ask the developer.
Thanks for your help.

mac os sierra pod install command failure

After moving to Mac OS Sierra, I'm facing problem to install cocoapods.
Every time I run sudo gem install cocoapods --pre every thing installed well, but while trying to install a pod, the terminal stack on Setting up CocoaPods master repo. Already updated the system with sudo gem update --system and still got the same issue, searched online to found old answers to use pod install --verbose Ss. I found in THIS answer fail again tells to install it manually.
NOTE: I have the latest version of 'Command Line Tools'. Any suggestion or how to install master repo manually?
Even when empty pod (i.e. without any pod name in it) is installed it gives
/Library/Ruby/Site/2.0.0/rubygems/dependency.rb:315:in `to_specs': Could not find 'cocoapods' (>= 0) among 66 total gem(s) (Gem::LoadError)
Checked in 'GEM_PATH=/Users/my_name/.gem/ruby/2.0.0:/Library/Ruby/Gems/2.0.0:/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/gems/2.0.0', execute `gem env` for more information
from /Library/Ruby/Site/2.0.0/rubygems/dependency.rb:324:in `to_spec'
from /Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_gem.rb:64:in `gem'
from /usr/local/bin/pod:22:in `'
Follow the instruction given below. It may help you.
check pod version using command given below
pod --version
if there is any version installed remove it by using the command
sudo gem uninstall cocoapods
restart your mac and reinstall again using the command
sudo gem install -n /usr/local/bin cocoapods
it will be security problem with mac os Sierra, i will try it and it will work for me . u can try it.
unable to load gem cocoa pods while creating repo

sass -v get Error phpstorm. Do not find SASS installation

I' ve installed ruby with rubygems , version 1.9.2. I've made an update and also install version 2.1.0 (last stable). And now I'll get an error at my phpStorm console. Before everything worked great.
If I check my sass-Version, I always get these output in console (terminal)
/Users/ssa/.rvm/rubies/ruby-2.1.0/bin/scss --no-cache --update --watch --sourcemap --debug-info styles.scss:/Users/ssa/Sites/staging_shop/.../css/styles.css
/Users/ssa/.rvm/rubies/ruby-2.1.0/lib/ruby/site_ruby/2.1.0/rubygems/dependency.rb:298:in `to_specs': Could not find 'sass' (>= 0) among 41 total gem(s) (Gem::LoadError)
from /Users/ssa/.rvm/rubies/ruby-2.1.0/lib/ruby/site_ruby/2.1.0/rubygems/dependency.rb:309:in `to_spec'
from /Users/ssa/.rvm/rubies/ruby-2.1.0/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_gem.rb:53:in `gem'
from /Users/ssa/.rvm/rubies/ruby-2.1.0/bin/scss:22:in `<main>'
Work on a MAC OS x 1.6.8
What's my problem? I don't know. Meanwhile I think I installed to much .. and have no idea what I#m doing.
try this out
first install saas-rails gem with command
gem install 'sass-rails'
and check sass version

Error while installing cocoapods

This is happening:
Mac:~ Swanros$ sudo gem install cocoapods
+Building native extensions. This could take a while...
ERROR: Error installing cocoapods:
ERROR: Failed to build gem native extension.
rake RUBYARCHDIR=/Users/Swanros/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/gems/2.0.0/gems/xcodeproj-0.14.0/ext RUBYLIBDIR=/Users/Swanros/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/gems/2.0.0/gems/xcodeproj-0.14.0/ext
/Users/Swanros/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/dependency.rb:296:in `to_specs': Could not find 'rake' (>= 0) among 9 total gem(s) (Gem::LoadError)
from /Users/Swanros/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/dependency.rb:307:in `to_spec'
from /Users/Swanros/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/site_ruby/2.0.0/rubygems/core_ext/kernel_gem.rb:47:in `gem'
from /Users/Swanros/.rvm/gems/ruby-2.0.0-p247/bin/rake:22:in `<main>'
Gem files will remain installed in /Users/Swanros/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/gems/2.0.0/gems/xcodeproj-0.14.0 for inspection.
Results logged to /Users/Swanros/.rvm/rubies/ruby-2.0.0-p247/lib/ruby/gems/2.0.0/gems/xcodeproj-0.14.0/ext/xcodeproj/gem_make.out
Mac:~ Swanros$
How could I solve this? I'm running OS X Mavericks with Xcode 5 Command Line Tools already installed.
I’ve just released xcodeproj 0.14.1 which contains a fix for this: https://github.com/CocoaPods/Xcodeproj/blob/0.14.1/CHANGELOG.md.
It should work if you try it again, or you can install the xcodeproj gem first and then try again:
$ sudo gem install xcodeproj
$ sudo gem install cocoapods
After updating Xcode 5 to Xcode 5.0.1, cocoapods can be installed successfully

Can't install RubyZip gem on OS X Lion with RVM

TL;DR:
$ gem install rubyzip
ERROR: While executing gem ... (Errno::EPERM)
Operation not permitted - /Users/darth/.rvm/gems/ruby-1.9.2-p136/gems/rubyzip-0.9.4/README
And now in detail. I'm not sure which information is relevant, so I'm just gonna say it all.
I recently upgraded from OS X Snow Leopard to Lion (also upgraded Xcode to 4.2)
Everything worked just fine for a while
Today I decided to install some gems (RSpec, Cucumber), and I started getting date format warnings whenever I did anything with RubyGems
I decided to update RubyGems, from 1.3.6 (I'm not sure here) to current 1.8.11
The warning kept on popping up, so I tried to remove the gemset with rvm gemset empty, which also failed, because of some permission denied error (yes stupid me didn't write it down)
In result of that, I reinstalled Ruby via rvm remove 1.9.2 and rvm install 1.9.2 (I didn't forget to rvm use 1.9.2 --default after that.
I installed bundler gem install bundle and then tried to bundle install in my Rails 3.1.1 project, but it ends with error
Installing rubyzip (0.9.4)
Errno::EPERM: Operation not permitted - /Users/darth/.rvm/gems/ruby-1.9.2-p136/gems/rubyzip-0.9.4/README
An error occured while installing rubyzip (0.9.4), and Bundler cannot continue.
Make sure that `gem install rubyzip -v '0.9.4'` succeeds before bundling.
gem install rubyzip -v '0.9.4' gives the above mentioned error
The README file says to download source and install from there via ruby install.rb, which also ends in error
$ ruby install.rb
/Users/darth/.rvm/rubies/ruby-1.9.2-p136/lib/ruby/1.9.1/fileutils.rb:841:in `install': wrong number of arguments (4 for 3) (ArgumentError)
from install.rb:21:in `block in <main>'
from install.rb:18:in `each'
from install.rb:18:in `<main>'
Even executing tests fro rubyzip ends up in bunch of errors
$ rake test
rake/gempackagetask is deprecated. Use rubygems/package_task instead
rake/rdoctask is deprecated. Use rdoc/task instead (in RDoc 2.4.2+)
/Users/darth/.rvm/rubies/ruby-1.9.2-p136/bin/ruby -C test alltests.rb
<internal:lib/rubygems/custom_require>:29:in `require': no such file to load -- stdrubyexttest (LoadError)
from <internal:lib/rubygems/custom_require>:29:in `require'
from alltests.rb:5:in `<main>'
rake aborted!
Command failed with status (1): [/Users/darth/.rvm/rubies/ruby-1.9.2-p136/b...]
Tasks: TOP => test
(See full trace by running task with --trace)
I'm out of ideas, what can I do?
I'm really not sure what caused this, but I managed to fix it by doing the following.
Since reinstalling Ruby 1.9.2 didn't help, I decided to be even more drastical and went down to rvm. I found out that I had version 1.1.something installed, which is about 9 months old.
I tried to update, but it didn't help, so rvm implode did the trick. I even had to sudo rm -rf ~/.rvm, probably because I managed to mess up some gem installs by adding sudo to them.
After reinstalling rvm and reinstalling 1.9.2, it seems like everything is working fine now, even with Xcode 4.2.
Lesson learned, rm -rf & reinstall is better than trying to upgrade from a year old version :)

Resources