SitePoint Sponsor

User Tag List

Results 1 to 6 of 6
  1. #1
    SitePoint Member
    Join Date
    Jul 2007
    0 Post(s)
    0 Thread(s)

    Please Help: Can not install Ruby on Windows XP

    I just bought the "Build Your Own Ruby on Rails Web Applications" by patrick Lenz. I am using windows xp. I followed the given installation instruction. Until page 43 which says you can start your own application by doing the following:

    1. cd shovell
    2 ruby script/server

    However. mine is not working. Please let me know what to do. Here what I did:

    C:\InstantRails>gem install rails --include-dependencies
    Attempting local installation of 'rails'
    Local gem file not found: rails*.gem
    Attempting remote installation of 'rails'
    Updating Gem source index for:
    Successfully installed rails-1.2.3
    Successfully installed rake-0.7.3
    Successfully installed activesupport-1.4.2
    Successfully installed activerecord-1.15.3
    Successfully installed actionpack-1.13.3
    Successfully installed actionmailer-1.3.3
    Successfully installed actionwebservice-1.2.3
    Installing RDoc documentation for rake-0.7.3...
    Installing RDoc documentation for activesupport-1.4.2...
    Installing RDoc documentation for activerecord-1.15.3...
    Installing RDoc documentation for actionpack-1.13.3...

    lib/action_controller/routing.rb:1061:30: ':' not followed by identified or oper

    lib/action_controller/routing.rb:1065:39: ':' not followed by identified or oper
    Installing RDoc documentation for actionmailer-1.3.3...
    Installing RDoc documentation for actionwebservice-1.2.3...

    C:\InstantRails>cd rails_apps

    Volume in drive C has no label.
    Volume Serial Number is 00CF-A337

    Directory of C:\InstantRails\rails_apps

    07/01/2007 01:42 PM <DIR> .
    07/01/2007 01:42 PM <DIR> ..
    07/01/2007 01:42 PM <DIR> cookbook
    07/01/2007 01:42 PM <DIR> typo-2.6.0
    0 File(s) 0 bytes
    4 Dir(s) 815,230,976 bytes free

    C:\InstantRails\rails_apps>rails shovell
    create app/controllers
    create app/helpers
    create app/models
    create app/views/layouts
    create config/environments
    create components
    create db
    create doc
    create lib
    create lib/tasks
    create log
    create public/images
    create public/javascripts
    create public/stylesheets
    create script/performance
    create script/process
    create test/fixtures
    create test/functional
    create test/integration
    create test/mocks/development
    create test/mocks/test
    create test/unit
    create vendor
    create vendor/plugins
    create tmp/sessions
    create tmp/sockets
    create tmp/cache
    create tmp/pids
    create Rakefile
    create README
    create app/controllers/application.rb
    create app/helpers/application_helper.rb
    create test/test_helper.rb
    create config/database.yml
    create config/routes.rb
    create public/.htaccess
    create config/boot.rb
    create config/environment.rb
    create config/environments/production.rb
    create config/environments/development.rb
    create config/environments/test.rb
    create script/about
    create script/breakpointer
    create script/console
    create script/destroy
    create script/generate
    create script/performance/benchmarker
    create script/performance/profiler
    create script/process/reaper
    create script/process/spawner
    create script/process/inspector
    create script/runner
    create script/server
    create script/plugin
    create public/dispatch.rb
    create public/dispatch.cgi
    create public/dispatch.fcgi
    create public/404.html
    create public/500.html
    create public/index.html
    create public/favicon.ico
    create public/robots.txt
    create public/images/rails.png
    create public/javascripts/prototype.js
    create public/javascripts/effects.js
    create public/javascripts/dragdrop.js
    create public/javascripts/controls.js
    create public/javascripts/application.js
    create doc/README_FOR_APP
    create log/server.log
    create log/production.log
    create log/development.log
    create log/test.log

    C:\InstantRails\rails_apps>cd shovell

    C:\InstantRails\rails_apps\shovell>ruby script/server
    ./script/../config/boot.rb:29: undefined method `gem' for main:Object (NoMethodE
    from C:/InstantRails/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require
    .rb:21:in `require'
    from script/server:2


  2. #2
    SitePoint Member
    Join Date
    Jul 2007
    0 Post(s)
    0 Thread(s)
    Forgot to tell you that when I go to the http://localhost:3000, it is not working!!!!!

  3. #3
    SitePoint Member
    Join Date
    Jul 2007
    0 Post(s)
    0 Thread(s)

    My problem has been fixed!!!

    I needed to do the following command first:
    gem update --system

    then I can do:

    ruby script/ server

    By the way, I got this solution from the the author!!!! I emailed him before I post my problem in this forum and he just responded to me!!!!

  4. #4
    SitePoint Wizard samsm's Avatar
    Join Date
    Nov 2001
    Atlanta, GA, USA
    0 Post(s)
    0 Thread(s)
    Note that the first Google result for the error (undefined method `gem' for main:Object) gets you the same answer. This works with enough errors that it is usually worth a shot.
    Using your unpaid time to add free content to SitePoint Pty Ltd's portfolio?

  5. #5
    SitePoint Member
    Join Date
    Aug 2007
    0 Post(s)
    0 Thread(s)
    thanks for the help

  6. #6
    SitePoint Member
    Join Date
    Sep 2007
    0 Post(s)
    0 Thread(s)
    thanks for the info! this fixed me too.
    (I figured it would be something like that)

    as a ruby starter I am very grateful to those who create such v/easy installs

    BUT I wish they were kept up to date! or the document include such
    'regular possibilities'

    especially if its from someone trying to sell you the 'how-to' book.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts