Installing Rails 2.3.4 - ruby-on-rails

I am working on a project that requires me to install Rails 2.3.4. I have only worked with Rails 3 applications, where I installed Rails 3 using RVM.
Since I am using a separate machine for this project, basically all I am asking for is how to install Rails 2.3.4. Any links would be much appreciated :)

did you try
sudo gem install rails -v=2.3.4

RVM http://beginrescueend.com/rvm/install/ is your best bet.
Which OS are you working with ?
The installation guide is for Linux. I don't have much experience with RVM on windows. But should be straightforward.
With RVM you get create gemsets which will give you advantage that you can run different rails version for different applications.
http://beginrescueend.com/gemsets/

gem install rails -v 2.3.4
gem install --help for more information.
There is no reason why the above can not be executed via rvm.

gem install -v=2.3.4 rails
or
sudo gem install -v=2.3.4 rails
It will install rails 2.3.4 version.

Related

downgrade to rails 2.3 from 3.1.1[how to]

I need to install redmine1.4 for that need to have my rails version2.3, but I have rails3 .
How can I downgrade my rails version -> Rails 2.3.14. Thanks
I not sure I get the question. From what I understand you want to install Redmine which requires rails 2.3.x but you have rails 3 gem installed. I'm not familar with redmine but I think it should use bundler and simple bundle install should do the trick.
If not, the simplest solution would be to uninstall rails 3 gem and install rails 2.3.x gem. For that you need to:
$ gem uninstall rails
$ gem install rails --version "2.3.14"
However this may broke your other apps which use rails 3.x ver. Thus I recommend using one of following tools for managing ruby versions and use feature called gemsets:
RVM
rbenv

How to install AuthLogic plugin for rails 2.3.5?

I am following a Ruby on Rails tutorial in a book that uses Acts As Authenticated, but this seems to no longer be supported. I was searching and came across a SO post which recommends a couple of different alternatives for doing user authentication in rails applications. I think AuthLogic looks like a good choice. I am using Rails 2.3.5 and Ruby 1.8.7.
The AuthLogic readme section states the following:
** Please note the latest version is compatible with rails 3 only. Rails 2
should use version 2.X.X **
However, when scrolling down to the section about installing as gem or plugin, it only gives the following examples:
Rails 3:
$ sudo gem install authlogic
Rails 2:
$ sudo gem install authlogic
--version=2.1.6
Or install as a plugin:
script/plugin install
git://github.com/binarylogic/authlogic.git
I want to install a plugin, rather than the gem, but I need to do it for 2.3.5, not for 3. Can I install the plugin by version in the same way that it shows how to install the gem by version? For example:
script/plugin install git://github.com/binarylogic/authlogic.git --version=2.3.5
If this is not how it is done, could someone please explain to me how to do it?
Thanks!
I really would reconsider using as a plugin and instead setup bundler in your project. Your Gemfile line would be gem 'authlogic', '2.1.6'. If you are concerned about packaging libraries with your project you can bundle pack to include your gems with your project.
Anyway, The following plugin install command should work.
script/plugin install git://github.com/binarylogic/authlogic.git -r 'tag v2.1.6'
Installing rails 2.3.5
Create the gemset:rvm gemset create rails2
2.Setting up rvm to use always this gemset:rvm use 1.8.7#rails2 –default
Gem install rails -v 2.3.5

how to update rails 2.3.5 to rails 3.0.1 in ubuntu 10.10

recently i installed rails 2.3.5 using apt-get. After installing rails 3.0.1 the version shows on as rails 2.3.5 when i type rails -v command. How to change that? or can i update rails 2.3.5 to 3.0.1? pls help me out
You should NOT use apt to manage your rubies or your gems! (NEVER)
Use RVM to manage your Rubies and your gems : http://rvm.io/
Try gem uninstall rails then select version of rails gem which you want to remove.
You can follow the upgrade directions given at http://guides.rubyonrails.org/3_0_release_notes.html
to install Rails 3 use this script..
sudo gem install rails --pre
It's possible to control version of Rails
rails _2.3.8_ --version
rails _3.0.0.rc_ --version
Hope it'll work. For more details https://help.ubuntu.com/community/RubyOnRails#Installing_rails it's a best url
Oh, I got another solution. Try this script, it'll work
sudo gem install -v=3.0.1 rails --include-dependencies

problem with rails instalation need 2.3.8 after installation still getting "rails -v" = "Rails 2.3.5"

I'm trying to setup clockingit but...
even after
gem install -v=2.3.8 rails
1 gem installed
i'm getting
rails -v
Rails 2.3.5
I need 2.3.8 to rake the gems for clockingit
help greatly apreciated
Try gem install -v 2.3.8 rails (no equal sign). You should also check if the version of Ruby on Rails installed through RubyGems is used at all. Maybe a version of Ruby on Rails installed through the package management of your operating system overlaps the version installed through RubyGems.
Try to use rvm. It is dead simple to deal with, and makes managing gems very easy. If you already on rvm, try to create another gemset
rvm gemset create new_gemset
and the try to install rails

Error putting Instant Rails on Windows 7

I am trying to get my Instant Rails working on my Windows 7 laptop.
The error I keep getting when trying to access my site files are:
c:/rails/ruby/lib/site_ruby/1.8/rubygems.rb:779:in 'report_activate_error'
RubyGem version error: rack<1.1.0 not~> 1.0.1> <Gem::LoadError>
from c:/rails/ruby/lib/ruby.site_ruby/1.8/rubygems.rb:214:in 'activate'
from c:/rails/ruby/lib/ruby.site_ruby/1.8/rubygems.rb:1082:in 'gem'
from c:/depot/vendor/rails/actionpack/lib/action_controller.rb:34
from c://rails/ruby/lib/ruby.site_ruby/1.8/rubygems/custom_require.rb:31 in 'gem_original_require'
etc...
I have intalled Rubygems 1.3.7 and they work fine and when I run the test it works and the gem env shows that the 1.3.7 has been installed correctly.
What can I do to get this working?
Any prompt help would be VERY appreciated.
Thanks
Your rack gem is outdated. Try to run gem update rack. Or, if you use Rails with Bundler, just run bundle install in the root of your project and it will do everything for you.
I decided to write a little manual about the Ruby 1.8.7 and Rails stable installation.
Download RubyInstaller 1.8.7 from here. During the installation, check the 'Add Ruby executables to your PATH' box. After the installation, don't forget to restard cmd. Then try running ruby -v and gem -v to check for installed Ruby 1.8.7 and RubyGems 1.3.7;
Install the latest stable Rails 2.3.8 using gem install rails --no-ri --no-rdoc; Check it using rails -v;
Create a new application using rails myapp;
Test it: script/server. That's it!
gem install rack -v 1.0.1

Resources