0

I just did a fresh rvm implode and thought that I might screw up less by installing everything with a clean slate from JewelryBox.

I also updated xcode to latest version (4.6.2).

Here is the problem:

➜  ~  rvm -v

rvm 1.19.6 (stable) by Wayne E. Seguin <wayneeseguin@gmail.com>, Michal Papis <mpapis@gmail.com> [https://rvm.io/]

➜  ~  ruby -v
ruby 2.0.0p0 (2013-02-24 revision 39474) [x86_64-darwin11.4.2]
➜  ~  gem -v
2.0.3
➜  ~  gem list

*** LOCAL GEMS ***

bigdecimal (1.2.0)
bundler (1.3.5)
io-console (0.4.2)
json (1.7.7)
minitest (4.3.2)
psych (2.0.0)
rake (10.0.4, 0.9.6)
rdoc (4.0.0)
rubygems-bundler (1.1.1)
rvm (1.11.3.7)
test-unit (2.0.0.0)
thor (0.18.1)
➜  ~  thor
zsh: /Users/hb/.rvm/gems/ruby-2.0.0-p0@global/bin/thor: bad interpreter: ruby_bundler_wrapper: no such file or directory
Commands:
  thor help [COMMAND]  # Describe available commands or one specific command
  thor install NAME    # Install an optionally named Thor file into your system commands
  thor installed       # List the installed Thor modules and commands
  thor list [SEARCH]   # List the available thor commands (--substring means .*SEARCH)
  thor uninstall NAME  # Uninstall a named Thor module
  thor update NAME     # Update a Thor file from its original location
  thor version         # Show Thor version


ls ~/.rvm/gems/ruby-2.0.0-p0@global/bin/
bundle                       guard                        rake                         rubygems-bundler-uninstaller
coderay                      pry                          ruby_noexec_wrapper          thor
➜  ~

TL;DR

Problem:

➜  ~  thor
zsh: /Users/hb/.rvm/gems/ruby-2.0.0-p0@global/bin/thor: bad interpreter: ruby_bundler_wrapper: no such file or directory
➜  ~  guard
zsh: /Users/hb/.rvm/gems/ruby-2.0.0-p0@global/bin/guard: bad interpreter: ruby_bundler_wrapper: no such file or directory

➜  ~  rake --help
zsh: /Users/hb/.rvm/gems/ruby-2.0.0-p0@global/bin/rake: bad interpreter: ruby_bundler_wrapper: no such file or directory
rake [-f rakefile] {options} targets...

Options are ...
        --backtrace=[OUT]            Enable full backtrace.  OUT can be stderr (default) or stdout.
        --comments                   Show commented tasks only
        --job-stats [LEVEL]          Display job statistics. LEVEL=history displays a complete job list
        --rules                      Trace the rules resolution.
        --suppress-backtrace PATTERN Suppress backtrace lines matching regexp PATTERN. Ignored if --trace is on.
    -A, --all                        Show all tasks, even uncommented ones
    -D, --describe [PATTERN]         Describe the tasks (matching optional PATTERN), then exit.
    -e, --execute CODE               Execute some Ruby code and exit.
    -E, --execute-continue CODE      Execute some Ruby code, then continue with normal task processing.
    -f, --rakefile [FILE]            Use FILE as the rakefile.
    -G, --no-system, --nosystem      Use standard project Rakefile search paths, ignore system wide rakefiles.
    -g, --system                     Using system wide (global) rakefiles (usually '~/.rake/*.rake').
    -I, --libdir LIBDIR              Include LIBDIR in the search path for required modules.
    -j, --jobs [NUMBER]              Specifies the maximum number of tasks to execute in parallel. (default:2)
    -m, --multitask                  Treat all tasks as multitasks.
    -n, --dry-run                    Do a dry run without executing actions.
    -N, --no-search, --nosearch      Do not search parent directories for the Rakefile.
    -P, --prereqs                    Display the tasks and dependencies, then exit.
    -p, --execute-print CODE         Execute some Ruby code, print the result, then exit.
    -q, --quiet                      Do not log messages to standard output.
    -r, --require MODULE             Require MODULE before executing rakefile.
    -R, --rakelibdir RAKELIBDIR,     Auto-import any .rake files in RAKELIBDIR. (default is 'rakelib')
        --rakelib
    -s, --silent                     Like --quiet, but also suppresses the 'in directory' announcement.
    -t, --trace=[OUT]                Turn on invoke/execute tracing, enable full backtrace. OUT can be stderr (default) or stdout.
    -T, --tasks [PATTERN]            Display the tasks (matching optional PATTERN) with descriptions, then exit.
    -v, --verbose                    Log message to standard output.
    -V, --version                    Display the program version.
    -W, --where [PATTERN]            Describe the tasks (matching optional PATTERN), then exit.
    -X, --no-deprecation-warnings    Disable the deprecation warnings.
    -h, -H, --help                   Display this help message.
➜  ~
4

1 回答 1

1

You need to remove custom_shebang from ~/.gemrc and run:

rvm all-gemsets --verbose do gem regenerate_binstubs

it might take some time, but should fix everything.

于 2013-04-29T15:48:38.803 回答