Cygwin + rubygem $B$G(B install $B%3%^%s%I$,JV$C$F$3$J$$(B

e$B=i$a$^$7$F!"$7$_$:e(B e$B$H?=$7$^$9!#e(B

cygwin e$B$Ge(B Ruby 1.9 e$B$r;HMQ$7$F$$$k$N$G$9$,e(B
gem install mechanize
e$B$H%3%^%s%IBG$C$F$b!"$3$N$^$^1~Ez$,JV$C$F$3$:!“e(BCtrl + C
e$B$G;_$a$k$7$+$”$j$^$;$s!#e(B
e$B$I$J$?$+!"e(Bcygwin e$B$Ge(B gem
e$B$,;H$($F$$$kJ}$O$$$i$C$7$c$$$^$9$G$7$g$&$+!#e(B
e$B%=%U%HB&$NLdBj$J$N$+4D6-$NLdBj$J$N$+CN$j$?$$$G$9!#e(B

e$B%G%P%C%0$7$F$_$?$H$3$me(B
net/http.rb e$B$Ne(B 576 e$B9TL\e(B e$B$Ne(B TCPSocket.open
e$B$GJV$C$FMh$F$$$J$$$H$3$m$^$G$OJ,$+$j$^$7$?!#e(B
574: def connect
575: D “opening connection to #{conn_address()}…”
576: s = timeout(@open_timeout) { TCPSocket.open(conn_address(),
conn_port()) }
577: D “opened”

e$B4D6-e(B
ruby 1.9.0 (2007-12-30 revision 0) [i386-cygwin]
e$B%$%s%9%H!<%k@h!'e(B/usr/local/bin
Windows XP Professional Service Pack 2
e$B$^$?!"e(Bsetup.exe e$B$Ge(B e$B%$%s%9%H!<%k$7$?e(B
ruby 1.8.6 (2007-03-13 patchlevel 0) [i386-cygwin] e$B$,e(B /usr/bin
e$B$KF~$C$F$$$^$9!#e(B

1.8 e$B$He(B 1.9 e$B$NN>J}$,F~$C$F$$$k$3$H$,LdBj$G$7$g$&$+!)e(B
e$BB>$K5-=R$9$Y$-4D6-$,$"$k>l9g$O$*CN$i$;$/$@$5$$!#e(B
e$B59$7$/$*4j$$$7$^$9!#e(B

e$B$3$s$K$A$O!";a5W$H?=$7$^$9!#e(B

cygwin e$B$Ge(B Ruby 1.9 e$B$r;HMQ$7$F$$$k$N$G$9$,e(B
gem install mechanize
e$B$H%3%^%s%IBG$C$F$b!"$3$N$^$^1~Ez$,JV$C$F$3$:!“e(BCtrl + C e$B$G;_$a$k$7$+$”$j$^$;$s!#e(B
e$B$I$J$?$+!"e(Bcygwin e$B$Ge(B gem e$B$,;H$($F$$$kJ}$O$$$i$C$7$c$$$^$9$G$7$g$&$+!#e(B
e$B%=%U%HB&$NLdBj$J$N$+4D6-$NLdBj$J$N$+CN$j$?$$$G$9!#e(B

e$B;d$bF1$84D6-$GF1$8LdBj$K%O%^$C$F$7$^$$$^$7$?!#e(B

[ruby-talk]e$B$G$bF1MM$N<ALd$r$7$??M$,$$$^$7$?$,!"JVEz$O$J$$$_$?$$$G$9!#e(B
gem install can not work in Cygwin Ruby1.9? - ruby-talk-google | Google
Groups
http://groups.google.com/group/ruby-talk-google/browse_thread/thread/57d6e401f60ed1c7

e$B$H$j$“$($:$N2r7h:v$H$7$F!”@h$Ke(Bfetche$B$7$F<hF@$7$?%m!<%+%k$N%U%!%$%k$KBP$7$Fe(Binstalle$B$7$F$$$^$9!#e(B
gem fetch rake
gem install ./rake-0.8.1.gem
e$B0MB84X78$,$“$k$H$^$?e(Binstalle$B$,;_$^$C$F$7$^$&$N$G!“4XO”$9$k%Q%C%1!<%8$re(B
e$B@h$Ke(Bfetche$B$7$Fe(Binstalle$B$7$F$*$/I,MW$,$”$j$=$&$G$9!#e(B

e$B$7$_$:$G$9!#e(B

gem fetch rake
gem install ./rake-0.8.1.gem
e$B0MB84X78$,$"$k$H$^$?e(Binstalle$B$,;_$^$C$F$7$^$&$N$G!“4XO”$9$k%Q%C%1!<%8$re(B
e$B@h$Ke(Bfetche$B$7$Fe(Binstalle$B$7$F$*$/I,MW$,$"$j$=$&$G$9!#e(B

e$BKM$N4D6-$G$O%(%i!<$,$G$^$9$M!&!&!&!#e(B
e$B0l1~!"e(B -d e$B$rIU$1$?;~$N%m%0$rE=$jIU$1$F$*$-$^$9!#e(B

$ gem fetch rake
Exception `NoMethodError’ at /usr/local/lib/ruby/1.9.0/rational.rb:77

  • undefined method gcd' for Rational(1, 2):Rational ExceptionErrno::ENOENT’ at
    /usr/local/lib/ruby/1.9.0/rubygems/config_file.rb:86 - No such file or
    directory - /home/Administrator/.gemrc
    Exception NameError' at /usr/local/lib/ruby/1.9.0/rubygems/command_manager.rb:132 - uninitialized constant Gem::Commands::FetchCommand ExceptionGem::LoadError’ at
    /usr/local/lib/ruby/1.9.0/rubygems.rb:385 - Could not find RubyGem
    sources (> 0.0.1)

Warning:/usr/local/lib/ruby/1.9.0/tmpdir.rb:14: Win32API is deprecated
after Ruby 1.9.1; use dl directly instead
/usr/local/lib/ruby/1.9.0/open-uri.rb:411: warning: instance variable
@meta not initialized
Exception `NoMethodError’ at /usr/local/lib/ruby/1.9.0/open-uri.rb:411

  • undefined method []=' for nil:NilClass ExceptionNoMethodError’ at /usr/local/lib/ruby/1.9.0/delegate.rb:146
  • undefined method []=' for nil:NilClass ExceptionGem::OperationNotSupportedError’ at
    /usr/local/lib/ruby/1.9.0/rubygems/source_index.rb:366 - No quick
    index found: undefined method []=' for nil:NilClass Bulk updating Gem source index for: http://gems.rubyforge.org /usr/local/lib/ruby/1.9.0/open-uri.rb:411: warning: instance variable @meta not initialized ExceptionNoMethodError’ at /usr/local/lib/ruby/1.9.0/open-uri.rb:411
  • undefined method []=' for nil:NilClass ExceptionNoMethodError’ at /usr/local/lib/ruby/1.9.0/delegate.rb:146
  • undefined method []=' for nil:NilClass /usr/local/lib/ruby/1.9.0/open-uri.rb:411: warning: instance variable @meta not initialized ExceptionNoMethodError’ at /usr/local/lib/ruby/1.9.0/open-uri.rb:411
  • undefined method []=' for nil:NilClass ExceptionNoMethodError’ at /usr/local/lib/ruby/1.9.0/delegate.rb:146
  • undefined method []=' for nil:NilClass /usr/local/lib/ruby/1.9.0/open-uri.rb:411: warning: instance variable @meta not initialized ExceptionNoMethodError’ at /usr/local/lib/ruby/1.9.0/open-uri.rb:411
  • undefined method []=' for nil:NilClass ExceptionNoMethodError’ at /usr/local/lib/ruby/1.9.0/delegate.rb:146
  • undefined method []=' for nil:NilClass /usr/local/lib/ruby/1.9.0/open-uri.rb:411: warning: instance variable @meta not initialized ExceptionNoMethodError’ at /usr/local/lib/ruby/1.9.0/open-uri.rb:411
  • undefined method []=' for nil:NilClass ExceptionNoMethodError’ at /usr/local/lib/ruby/1.9.0/delegate.rb:146
  • undefined method []=' for nil:NilClass ExceptionGem::RemoteSourceException’ at
    /usr/local/lib/ruby/1.9.0/rubygems/source_index.rb:354 - Error
    fetching remote gem cache: undefined method []=' for nil:NilClass ERROR: While executing gem ... (Gem::RemoteSourceException) Error fetching remote gem cache: undefined method[]=’ for
    nil:NilClass
    /usr/local/lib/ruby/1.9.0/rubygems/source_index.rb:354:in
    raise' /usr/local/lib/ruby/1.9.0/rubygems/source_index.rb:354:infetch_bulk_index’
    /usr/local/lib/ruby/1.9.0/rubygems/source_index.rb:292:in
    update' /usr/local/lib/ruby/1.9.0/rubygems/source_info_cache_entry.rb:33:inrefresh’
    /usr/local/lib/ruby/1.9.0/rubygems/source_info_cache.rb:135:in
    block in refresh' /usr/local/lib/ruby/1.9.0/rubygems/source_info_cache.rb:128:ineach’
    /usr/local/lib/ruby/1.9.0/rubygems/source_info_cache.rb:128:in
    refresh' /usr/local/lib/ruby/1.9.0/rubygems/source_info_cache.rb:40:incache’
    /usr/local/lib/ruby/1.9.0/rubygems/source_info_cache.rb:56:in
    search_with_source' /usr/local/lib/ruby/1.9.0/rubygems/commands/fetch_command.rb:41:inblock in execute’
    /usr/local/lib/ruby/1.9.0/rubygems/commands/fetch_command.rb:39:in
    each' /usr/local/lib/ruby/1.9.0/rubygems/commands/fetch_command.rb:39:inexecute’
    /usr/local/lib/ruby/1.9.0/rubygems/command.rb:136:in invoke' /usr/local/lib/ruby/1.9.0/rubygems/command_manager.rb:104:inprocess_args’
    /usr/local/lib/ruby/1.9.0/rubygems/command_manager.rb:74:in
    run' /usr/local/lib/ruby/1.9.0/rubygems/gem_runner.rb:39:inrun’
    /usr/local/bin/gem:22:in `’
    removing
    /cygdrive/c/DOCUME~1/ADMINI~1/LOCALS~1/Temp/open-uri20080106-1208-jihacd-0…done
    removing
    /cygdrive/c/DOCUME~1/ADMINI~1/LOCALS~1/Temp/open-uri20080106-1208-1kdilx7-0…done
    removing
    /cygdrive/c/DOCUME~1/ADMINI~1/LOCALS~1/Temp/open-uri20080106-1208-1m9hlz1-0…done
    removing
    /cygdrive/c/DOCUME~1/ADMINI~1/LOCALS~1/Temp/open-uri20080106-1208-1egrvhf-0…done
    removing
    /cygdrive/c/DOCUME~1/ADMINI~1/LOCALS~1/Temp/open-uri20080106-1208-hq9bfi-0…done