Any thoughts on building a project using an old version of rails?

I am trying to build some sample projects from the book “Ajax on
Rails.” These projects are built against Rails 1.1.5, I am using Rails
2.0.2.

The directions are to copy the sample code to your code folder, add
all the default rails files, and then edit config/database.yml.

So I installed the rails 1.1.5 gem, and then added the default files
with

rails 1.1.5 -s photo_gallery

But then script/server won’t work. It ran into two occurrences of
“require_gem” that seem to now need to be “require” in boot.rb. I
changed those lines, and now I get

script/server

/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/
1.8/rubygems/custom_require.rb:27:in gem_original_require': no such file to load -- rails (LoadError) from /System/Library/Frameworks/Ruby.framework/Versions/1.8/ usr/lib/ruby/1.8/rubygems/custom_require.rb:27:in require’
from ./script/…/config/boot.rb:38
from script/server:2:in `require’
from script/server:2

And, for what it is worth, I can’t seem to freeze rails into this
project or even into a new project. When I try

rails 1.1.5 -f test_frozen

it generates all the rails files, but then when it tries to freeze the
code I get the error message

/Library/Ruby/Gems/1.8/gems/rails-1.1.5/bin/rails:19:in chdir': No such file or directory - -f (Errno::ENOENT) from /Library/Ruby/Gems/1.8/gems/rails-1.1.5/bin/rails:19 from /usr/bin/rails:19:in load’
from /usr/bin/rails:19

Is it just impossible to run an old version of rails?

If the answer is yes–then perhaps there is more modern example code
that will allow me to experiment with script.aculo.us and JavaScript?
Pointers?

Thanks

On 4 Jun 2008, at 06:19, alanterra wrote:

rails 1.1.5 -s photo_gallery

But then script/server won’t work. It ran into two occurrences of
“require_gem” that seem to now need to be “require” in boot.rb. I
changed those lines, and now I get

The replacement for require_gem is gem

Fred

Thanks Frederick, that was the help I needed.

For anyone who stumbles across this post, a recipe for building
“Example B: Photo Gallery” from “Ajax on Rails” by Scott R. is

download and unzip the archives from the book
copy the code from “Photo Archive” to a folder named
“photo_archive” (for convenience)
install rails 1.2.5 you don’t have it (gem install rails -v=1.2.5)
install the standard rails files in photo_archive (rails 1.2.5
photo_archive -s)
change “require_gem” to “gem” in two places in config/boot.rb
change RAILS_GEM_VERSION to ‘1.2.5’ in config/environment.rb
configure the database and make an sql database if you need to
run two rake tasks: rake rails:update; rake db:schema:load

For whatever reason, it wouldn’t build against rails 1.1.5 which it
says it wants

Again, thanks

A