rbenv: no such command `install'が出てinstallできない時の対処法

f:id:komeiy:20141223135843j:plain

rbenv: no such command `install'が出た時の対処方法です。

エラー内容の確認

  • エラーメッセージ確認
[komei@localhost ~]$ rbenv install --list
rbenv: no such command `install'
  • コマンド一覧確認
[komei@localhost ~]$ rbenv -h
rbenv 0.4.0-129-g7e0e85b
Usage: rbenv <command> [<args>]

Some useful rbenv commands are:
   commands    List all available rbenv commands
   local       Set or show the local application-specific Ruby version
   global      Set or show the global Ruby version
   shell       Set or show the shell-specific Ruby version
   rehash      Rehash rbenv shims (run this after installing executables)
   version     Show the current Ruby version and its origin
   versions    List all Ruby versions available to rbenv
   which       Display the full path to an executable
   whence      List all Ruby versions that contain the given executable

See `rbenv help <command>' for information on a specific command.
For full documentation, see: https://github.com/sstephenson/rbenv#readme

rbenv: no such command `install'の対象方法

以下の通り、ruby-buildをgitからcloneしてください。場所はrbenvをcloneした場所に合わせて適宜変更してください。

[komei@localhost ~]$ git clone https://github.com/sstephenson/ruby-build.git ~/.rbenv/plugins/ruby-build
[komei@localhost ~]$ rbenv install --list
Available versions:
  1.8.6-p383
  1.8.6-p420
  1.8.7-p249

シェアして頂けると嬉しいです。
参考になったという方がいれば是非お願いしますm(_ _ )m
モチベーション維持の観点で非常に励みになります。

このエントリーをはてなブックマークに追加

パーフェクトRuby (PERFECT SERIES 6)

パーフェクトRuby (PERFECT SERIES 6)