尝试运行berks install
$ berks install
Resolving cookbook dependencies...
Fetching 'collectd' from https://github.com/librato/collectd-cookbook.git (at master)
Fetching 'collectd-librato' from https://github.com/librato/collectd-librato-cookbook.git (at master)
Fetching 'influxdb' from https://github.com/svs/chef-influxdb.git (at master)
Fetching 'monit' from https://github.com/apsoto/monit.git (at master)
Fetching 'nginx_conf' from https://github.com/firebelly/chef-nginx_conf.git (at master)
Fetching 'papertrail-rsyslog' from https://github.com/hipsnip-cookbooks/papertrail-rsyslog.git (at master)
Fetching 'rvm' from https://github.com/fnichol/chef-rvm.git (at master)
Fetching 's3cmd' from https://github.com/fred/chef-s3cmd.git (at master)
Fetching cookbook index from https://supermarket.getchef.com...
/Users/svs/.rvm/rubies/ruby-2.1.0/lib/ruby/2.1.0/json/common.rb:155:in `encode': "\xE2" on US-ASCII (Encoding::InvalidByteSequenceError)
from /Users/svs/.rvm/rubies/ruby-2.1.0/lib/ruby/2.1.0/json/common.rb:155:in `initialize'
from /Users/svs/.rvm/rubies/ruby-2.1.0/lib/ruby/2.1.0/json/common.rb:155:in `new'
from /Users/svs/.rvm/rubies/ruby-2.1.0/lib/ruby/2.1.0/json/common.rb:155:in `parse'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/ridley-4.0.0/lib/ridley/chef/cookbook/metadata.rb:458:in `from_json'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/ridley-4.0.0/lib/ridley/chef/cookbook/metadata.rb:29:in `from_json'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/ridley-4.0.0/lib/ridley/chef/cookbook.rb:36:in `from_path'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/berkshelf-3.1.4/lib/berkshelf/cached_cookbook.rb:15:in `from_store_path'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/berkshelf-3.1.4/lib/berkshelf/cookbook_store.rb:108:in `block in cookbooks'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/berkshelf-3.1.4/lib/berkshelf/cookbook_store.rb:98:in `collect'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/berkshelf-3.1.4/lib/berkshelf/cookbook_store.rb:98:in `cookbooks'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/berkshelf-3.1.4/lib/berkshelf/resolver/graph.rb:8:in `populate_store'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/berkshelf-3.1.4/lib/berkshelf/resolver.rb:73:in `resolve'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/berkshelf-3.1.4/lib/berkshelf/installer.rb:174:in `install_from_universe'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/berkshelf-3.1.4/lib/berkshelf/installer.rb:39:in `run'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/berkshelf-3.1.4/lib/berkshelf/berksfile.rb:371:in `install'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/berkshelf-3.1.4/lib/berkshelf/cli.rb:143:in `install'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/thor-0.18.1/lib/thor/command.rb:27:in `run'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/thor-0.18.1/lib/thor/invocation.rb:120:in `invoke_command'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/thor-0.18.1/lib/thor.rb:363:in `dispatch'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/berkshelf-3.1.4/lib/berkshelf/cli.rb:52:in `dispatch'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/thor-0.18.1/lib/thor/base.rb:439:in `start'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/berkshelf-3.1.4/lib/berkshelf/cli.rb:27:in `execute!'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/gems/berkshelf-3.1.4/bin/berks:5:in `<top (required)>'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/bin/berks:23:in `load'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/bin/berks:23:in `<main>'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/bin/ruby_executable_hooks:15:in `eval'
from /Users/svs/.rvm/gems/ruby-2.1.0@kirana/bin/ruby_executable_hooks:15:in `<main>'
我不知道如何解决它。
谢谢!
答案 0 :(得分:5)
在终端中执行export LANG=en_US.UTF-8
答案 1 :(得分:0)
此外:
export LC_CTYPE=en_US.UTF-8
LANGUAGE=en_US:en