Вы находитесь на странице: 1из 16

Tags:

Updated Jan 30, 2009 by Harry Bishop

Instructions stitched together from several sources and tested as working Add user as a sudoer by logging in as root and executing $: echo 'loginname ALL=(ALL) ALL' >> /etc/sudoers install gcc compiler from gcc.gnu.org sudo yum grouplist sudo yum install zlib-devel sudo yum install ruby ruby-libs ruby-devel ruby-irb ruby-ri ruby-rdoc ruby-docs sudo yum install eruby eruby-libs eruby-devel bsf ruby-tcltk extract rubygems 0.9.5 sudo ruby setup.rb install -c -m 0644 rubygems/commands/dependency_command.rb /usr/lib/ruby/site_ruby/1.8/rubygems/commands /dependency_command.rb cp gem /tmp/gem install -c -m 0755 /tmp/gem /usr/bin/gem rm /tmp/gem

rm -f /home/<user>/.gem/source_cache rm -f /usr/lib/ruby/gems/1.8/source_cache Removing old RubyGems RDoc and ri rm -rf /usr/lib/ruby/gems/1.8/doc/rubygems-1.0.1 Installing rubygems-1.3.1 ri into /usr/lib/ruby/gems/1.8/doc/rubygems-1.3.1/ri Installing rubygems-1.3.1 rdoc into /usr/lib/ruby/gems/1.8/doc/rubygems-1.3.1/rdoc -----------------------------------------------------------------------------= Announce: RubyGems Release 1.3.0 NOTE: RubyGems 1.1 and 1.2 have problems upgrading when there is no rubygems-update installed. You will need to follow the second set of update instructions if you see "Nothing to update". Release 1.3.0 fixes some bugs. Bugs fixed: * Disregard ownership of ~ under Windows while creating ~/.gem. Fixes issues related to no uid support under Windows. * Fix requires for Gem::inflate, Gem::deflate, etc. * Make Gem.dir respect :gemhome value from config. (Note: this feature may be removed since it is hard to implement on 1.9.) * Kernel methods are now private. Patch #20801 by Stefan Rusterholz. * Gem::location_of_caller now behaves on Windows. Patch by Daniel Berger.

* Silence PATH warning. Deprecation Notices: * Gem::manage_gems will be removed on or after March 2009. For a full list of changes to RubyGems and the contributor for each change, see the ChangeLog file. Special thanks to Chad Wooley for backwards compatibility testing and Luis Lavena for continuing windows support. == How can I get RubyGems? NOTE: If you have installed RubyGems using a package system you may want to install a new RubyGems through the same packaging system. If you have a recent version of RubyGems (0.8.5 or later), then all you need to do is: $ gem update --system (you might need to be admin/root) NOTE: RubyGems 1.1 and 1.2 have problems upgrading when there is no rubygems-update installed. You will need to follow the second set of update instructions if you see "Nothing to update".

NOTE: You may have to run the command twice if you have any previosly installed rubygems-update gems. If you have an older version of RubyGems installed, then you can still do it in two steps: $ gem install rubygems-update (again, might need to be admin/root) $ update_rubygems (... here too) If you don't have any gems install, there is still the pre-gem approach to getting software ... doing it manually: 1. DOWNLOAD FROM: http://rubyforge.org/frs/?group_id=126 2. UNPACK INTO A DIRECTORY AND CD THERE 3. INSTALL WITH: ruby setup.rb (you may need admin/root privilege) == To File Bugs The RubyGems bug tracker can be found on RubyForge at: http://rubyforge.org/tracker/?func=add&group_id=126&atid=575 When filing a bug, `gem env` output will be helpful in diagnosing the issue. If you find a bug where RubyGems crashes, please provide debug output. You can do that with `gem --debug the_command`.

== Thanks Keep those gems coming! -- Jim & Chad & Eric (for the RubyGems team)

-----------------------------------------------------------------------------RubyGems installed the following executables: /usr/bin/gem If `gem` was installed by a previous RubyGems installation, you may need to remove it by hand. RubyGems system software updated SQLITE3 installation [rubygems-1.0.1]$ ls /var/cache/yum/fedora cachecookie filelists.sqlite other.sqlite primary.sqlite Fedora-9-comps.xml.gz mirrorlist.txt packages repomd.xml [rubygems-1.0.1]$ cd /var/cache/yum/fedora [fedora]$ file filelists.sqlite primary.sqlite filelists.sqlite: SQLite 3.x database primary.sqlite: SQLite 3.x database [fedora]$ sudo yum -y install ruby-sqlite3 Loaded plugins: refresh-packagekit

Setting up Install Process Parsing package install arguments Resolving Dependencies --> Running transaction check ---> Package ruby-sqlite3.i386 0:1.2.1-2.fc9 set to be updated --> Finished Dependency Resolution Dependencies Resolved ================================================================================ Package Arch Version Repository Size ================================================================================ Installing: ruby-sqlite3 i386 1.2.1-2.fc9 fedora 46 k Transaction Summary ================================================================================ Install 1 Package(s) Update 0 Package(s) Remove 0 Package(s) Total download size: 46 k Downloading Packages: ruby-sqlite3-1.2.1-2.fc9.i386.rpm | 46 kB 00:00 ============================== Entering rpm code =============================== Running rpm_check_debug

Running Transaction Test Finished Transaction Test Transaction Test Succeeded Running Transaction Installing : ruby-sqlite3 1/1 =============================== Leaving rpm code =============================== Installed: ruby-sqlite3.i386 0:1.2.1-2.fc9 Complete! RAILS 2.1.0 INSTALL [fedora]$ sudo gem install rails -v 2.1.0 [sudo] password: Successfully installed rake-0.8.3 Successfully installed activesupport-2.1.0 Successfully installed activerecord-2.1.0 Successfully installed actionpack-2.1.0 Successfully installed actionmailer-2.1.0 Successfully installed activeresource-2.1.0 Successfully installed rails-2.1.0 7 gems installed Installing ri documentation for rake-0.8.3... Installing ri documentation for activesupport-2.1.0... Installing ri documentation for activerecord-2.1.0...

Installing ri documentation for actionpack-2.1.0... Installing ri documentation for actionmailer-2.1.0... Installing ri documentation for activeresource-2.1.0... Installing RDoc documentation for rake-0.8.3... Installing RDoc documentation for activesupport-2.1.0... Installing RDoc documentation for activerecord-2.1.0... Installing RDoc documentation for actionpack-2.1.0... Installing RDoc documentation for actionmailer-2.1.0... Installing RDoc documentation for activeresource-2.1.0... INSTALL MONGREL SERVER [fedora]$ sudo gem install mongrel [sudo] password: Building native extensions. This could take a while... Building native extensions. This could take a while... Successfully installed gem_plugin-0.2.3 Successfully installed daemons-1.0.10 Successfully installed fastthread-1.0.1 Successfully installed cgi_multipart_eof_fix-2.5.0 Successfully installed mongrel-1.1.5 5 gems installed Installing ri documentation for gem_plugin-0.2.3... Installing ri documentation for daemons-1.0.10... Installing ri documentation for fastthread-1.0.1... No definition for dummy_dump

No definition for dummy_dump No definition for rb_queue_marshal_load No definition for rb_queue_marshal_dump Installing ri documentation for cgi_multipart_eof_fix-2.5.0... Installing ri documentation for mongrel-1.1.5... Installing RDoc documentation for gem_plugin-0.2.3... Installing RDoc documentation for daemons-1.0.10... Installing RDoc documentation for fastthread-1.0.1... No definition for dummy_dump No definition for dummy_dump No definition for rb_queue_marshal_load No definition for rb_queue_marshal_dump Installing RDoc documentation for cgi_multipart_eof_fix-2.5.0... Installing RDoc documentation for mongrel-1.1.5... GET A LIST OF INSTALLED GEMS [fedora]$ gem list *** LOCAL GEMS ***

actionmailer (2.1.0) actionpack (2.1.0) activerecord (2.1.0) activeresource (2.1.0) activesupport (2.1.0) cgi_multipart_eof_fix (2.5.0) daemons (1.0.10) fastthread (1.0.1) gem_plugin (0.2.3) mongrel (1.1.5) rails (2.1.0) rake (0.8.3) rubygems-update (1.3.1) [fedora]$ sudo gem update --system Updating RubyGems Nothing to update [fedora]$ sudo gem update rake Updating installed gems Nothing to update [fedora]$ sudo gem update ruby-sqlite3 Updating installed gems Nothing to update [fedora]$ gem list *** LOCAL GEMS ***

actionmailer (2.1.0) actionpack (2.1.0) activerecord (2.1.0) activeresource (2.1.0) activesupport (2.1.0) cgi_multipart_eof_fix (2.5.0) daemons (1.0.10) fastthread (1.0.1) gem_plugin (0.2.3) mongrel (1.1.5) rails (2.1.0) rake (0.8.3) rubygems-update (1.3.1) INSTALL CAPISTRANO [fedora]$ sudo gem install capistrano Successfully installed net-ssh-2.0.8 Successfully installed net-sftp-2.0.1 Successfully installed net-scp-1.0.1 Successfully installed net-ssh-gateway-1.0.0 Successfully installed highline-1.5.0 Successfully installed capistrano-2.5.3 6 gems installed Installing ri documentation for net-ssh-2.0.8... Installing ri documentation for net-sftp-2.0.1...

Installing ri documentation for net-scp-1.0.1... Installing ri documentation for net-ssh-gateway-1.0.0... Installing ri documentation for highline-1.5.0... Installing ri documentation for capistrano-2.5.3... Installing RDoc documentation for net-ssh-2.0.8... Installing RDoc documentation for net-sftp-2.0.1... Installing RDoc documentation for net-scp-1.0.1... Installing RDoc documentation for net-ssh-gateway-1.0.0... Installing RDoc documentation for highline-1.5.0... Installing RDoc documentation for capistrano-2.5.3... UPDATE ANY GEMS [fedora]$ sudo gem update mongrel Updating installed gems Nothing to update CREATE A DIRECTORY FOR RAILS APPS [fedora]$ cd ~/ [<user>@localhost ~]$ ls Desktop Documents Download Music Pictures Public Templates Videos [<user>@localhost ~]$ mkdir RailsApps [<user>@localhost ~]$ ls Desktop Download Pictures RailsApps Videos Documents Music Public Templates [<user>@localhost ~]$ cd RailsApps [<user>@localhost RailsApps]$ ls

CREATE YOUR RAILS APP [<user>@localhost RailsApps]$ rails expenses create create app/controllers create app/helpers create app/models create app/views/layouts create config/environments create config/initializers 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/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 config/initializers/inflections.rb create config/initializers/mime_types.rb create config/initializers/new_rails_defaults.rb 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/console create script/dbconsole create script/destroy create script/generate create script/performance/benchmarker create script/performance/profiler

create script/performance/request 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/422.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 [<user>@localhost RailsApps]$ ls expenses [<user>@localhost RailsApps]$ ls expenses app db lib public README test vendor config doc log Rakefile script tmp [<user>@localhost RailsApps]$

Вам также может понравиться