29
8

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

[初期設定]なぜ「.ruby-version」を作成するのか?

Last updated at Posted at 2018-06-11

「.ruby-version」をなぜ作成するのか?

他の開発者と同じバージョンを使うようにするため。
.ruby-versionをプロジェクトルートに配置します。

.ruby-versionのセットアップ

次のコマンドを実行すると、.ruby-versionファイルが生成されます。

rbenv local 2.4.1

# rbenv localコマンドを実行すると、.ruby-versionで指定したバージョンのRubyが使われるよに設定できます。
rbenv local (version指定 / ex.2.4.1)

rbenv の挙動

ruby-version.jpg

29
8
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
29
8

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?