$ gem install bundler jekyll
ERROR: While executing gem ... (Gem::FilePermissionError)
You don't have write permissions for the /Library/Ruby/Gems/2.6.0 directory.
$ xcode-select --install
xcode-select: error: command line tools are already installed, use "Software Update" to install updates
$ brew update
Updated 2 taps (homebrew/core and homebrew/cask).
$ brew install rbenv ruby-build
Updating Homebrew...
Error: The following directories are not writable by your user:
/usr/local/lib/pkgconfig
/usr/local/share/info
/usr/local/share/man/man3
/usr/local/share/man/man5
You should change the ownership of these directories to your user.
sudo chown -R $(whoami) /usr/local/lib/pkgconfig /usr/local/share/info /usr/local/share/man/man3 /usr/local/share/man/man5
And make sure that your user has write permission.
chmod u+w /usr/local/lib/pkgconfig /usr/local/share/info /usr/local/share/man/man3 /usr/local/share/man/man5
$ sudo chown -R $(whoami) /usr/local/lib/pkgconfig /usr/local/share/info /usr/local/share/man/man3 /usr/local/share/man/man5
...
$ brew install rbenv ruby-build
...
$ rbenv -v
rbenv 1.1.2
$ rbenv install -l
2.5.8
2.6.6
2.7.2
3.0.0
jruby-9.2.14.0
mruby-2.1.2
rbx-5.0
truffleruby-20.3.0
truffleruby+graalvm-20.3.0
$ rbenv install 3.0.0
...
Installed ruby-3.0.0 to /Users/seunghoonlee/.rbenv/versions/3.0.0
$ rbenv versions
* system (set by /Users/seunghoonlee/.rbenv/version)
3.0.0
$ rbenv global 3.0.0
$ rbenv versions
system
* 3.0.0 (set by /Users/seunghoonlee/.rbenv/version)
# 20210119 ADD
[[ -d ~/.rbenv ]] && \
export PATH=${HOME}/.rbenv/bin:${PATH} && \
eval "$(rbenv init -)"
$ source ~/.zshrc
$ ruby -v
ruby 3.0.0p0 (2020-12-25 revision 95aff21468) [x86_64-darwin19]
$ gem install bundler
Fetching bundler-2.2.5.gem
Successfully installed bundler-2.2.5
Parsing documentation for bundler-2.2.5
Installing ri documentation for bundler-2.2.5
Done installing documentation for bundler after 3 seconds
1 gem installed
$ jekyll serve
/Users/seunghoonlee/.rbenv/versions/3.0.0/lib/ruby/gems/3.0.0/gems/bundler-2.2.5/lib/bundler/resolver.rb:314:in `block in verify_gemfile_dependencies_are_found!': Could not find gem 'jekyll (~> 3.5)' in any of the gem sources listed in your Gemfile. (Bundler::GemNotFound)
$ bundle exec jekyll serve
Could not find gem 'jekyll (~> 3.5)' in any of the gem sources listed in your Gemfile.
Run `bundle install` to install missing gems.
$ bundle install
Fetching gem metadata from https://rubygems.org/..........
Fetching gem metadata from https://rubygems.org/.
Resolving dependencies...
Using ...
Bundle complete! 2 Gemfile dependencies, 38 gems now installed.
$ jekyll serve
/Users/seunghoonlee/.rbenv/versions/3.0.0/lib/ruby/gems/3.0.0/gems/bundler-2.2.5/lib/bundler/runtime.rb:302:in `check_for_activated_spec!': You have already activated i18n 1.8.7, but your Gemfile requires i18n 0.9.5. Prepending `bundle exec` to your command may solve this. (Gem::LoadError)
...
Dependency Error: Yikes! It looks like you don't have kramdown-parser-gfm or one of its dependencies installed. In order to use Jekyll as currently configured, you'll need to install this gem. The full error message from Ruby is: 'cannot load such file -- kramdown-parser-gfm' If you run into trouble, you can find helpful resources at https://jekyllrb.com/help/!
Conversion error: Jekyll::Converters::Markdown encountered an error while converting '_posts/9_PROJECT/2017-06-05-making_meal_alarming_bot.md':
kramdown-parser-gfm
ERROR: YOUR SITE COULD NOT BE BUILT:
------------------------------------
kramdown-parser-gfm
source "https://rubygems.org"
gem "jekyll", "~> 3.5"
gem "minimal-mistakes-jekyll"
gem "kramdown-parser-gfm"
$ bundle exec jekyll serve
Configuration file: /Users/seunghoonlee/frhyme.github.io/_config.yml
Source: /Users/seunghoonlee/frhyme.github.io
Destination: /Users/seunghoonlee/frhyme.github.io/_site
Incremental build: disabled. Enable with --incremental
Generating...
Jekyll Feed: Generating feed for posts
done in 337.821 seconds.
Auto-regeneration: enabled for '/Users/seunghoonlee/frhyme.github.io'
bundler: failed to load command: jekyll (/Users/seunghoonlee/.rbenv/versions/3.0.0/bin/jekyll)
/Users/seunghoonlee/.rbenv/versions/3.0.0/lib/ruby/gems/3.0.0/gems/jekyll-3.9.0/lib/jekyll/commands/serve/servlet.rb:3:in `require': cannot load such file -- webrick (LoadError)
...
$ bundle exec jekyll serve --incremental
Configuration file: /Users/seunghoonlee/frhyme.github.io/_config.yml
Source: /Users/seunghoonlee/frhyme.github.io
Destination: /Users/seunghoonlee/frhyme.github.io/_site
Incremental build: enabled
Generating...
Jekyll Feed: Generating feed for posts
done in 361.071 seconds.
Auto-regeneration: enabled for '/Users/seunghoonlee/frhyme.github.io'
Server address: http://127.0.0.1:4000
Server running... press ctrl-c to stop.
댓글남기기