Skip to content

Commit

Permalink
Document file option for ruby directive
Browse files Browse the repository at this point in the history
  • Loading branch information
albertchae committed Feb 6, 2024
1 parent 5968648 commit 18fc567
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions source/guides/gemfile_ruby.html.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,18 @@ It's also possible to restrict the patchlevel of the Ruby used by doing the foll
ruby '1.9.3', :patchlevel => '448'
~~~

If you wish to derive your Ruby version from a version file (i.e. `.ruby-version`),
you can use the `file` option instead.

~~~ruby
ruby file: ".ruby-version"
~~~

The version file should conform to any of the following formats:

- `3.1.2` (`.ruby-version`)
- `ruby 3.1.2` ([`.tool-versions`](https://asdf-vm.com/manage/configuration.html#tool-versions))

Bundler will make checks against the current running Ruby VM to make sure it matches what is specified in the `Gemfile`. If things don't match, Bundler will raise an Exception explaining what doesn't match.

~~~
Expand Down

0 comments on commit 18fc567

Please sign in to comment.