View
Posted about 3 years ago. Visible to the public.

How to find out your current Rails LTS version

As a customer of a paid plan who has installed Rails LTS with Bundler, run the following:

Copy
bundle show rails

As a customer of a paid plan who has installed Rails LTS without Bundler, run the following:

Copy
gem list | grep rails

As a subscriber to the free Community edition, run the following:

Copy
# on 2.3 $ script/runner 'puts RailsLts::VERSION.to_s' # say "script/runner -e production ..." on production # on 3.2 $ rails runner 'puts RailsLts::VERSION.to_s' #say "script/runner -e production ..." on production

That command will not work on older versions since RailsLts::VERSION did not exist back then. You will encounter an error like this:

Copy
.../gems/railslts-bcf87a3aad2b/activesupport/lib/active_support/dependencies.rb:469:in `load_missing_constant': uninitialized constant RailsLts (NameError)

In such cases you can be confident that you are not on the most recent version and should update to the latest release now.

Author of this card:

Avatar
Arne Hartherz
Last edit:
about 1 year ago
by Henning Koch
13 cards