# Gem under cygwin - is it supposed to work?

**URL:** <https://www.ruby-forum.com/t/gem-under-cygwin-is-it-supposed-to-work/104141>\
**Category:** Ruby\
**Created:** [May 14, 2007, 6:17pm UTC](https://www.ruby-forum.com/t/gem-under-cygwin-is-it-supposed-to-work/104141 "2007-05-14T18:17:26Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ronaldfischer](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/67e7ee/32.png) [@ronaldfischer](https://www.ruby-forum.com/u/ronaldfischer)\
**Post date:** [May 14, 2007, 6:17pm UTC](https://www.ruby-forum.com/t/gem-under-cygwin-is-it-supposed-to-work/104141/1 "2007-05-14T18:17:26Z")

</div>

I am using two installation of Ruby 1.8.5 - one running natively under  
Windows, and one  
bundled with Cygwin.

The Cygwin installation does not come with gem, so after I had installed  
gem 0.9.3 under  
Windows, I installed it within my Cygwin environment.

Contrary to the installation under Windows, which issued an error  
message, but left me  
with a supposedly working “gem” (I have described this problem in a  
separate thread),  
the Cygwin installation of gem worked without errors, but the usage of  
the package  
does not seem to work:

$ gem install net-ssh  
Bulk updating Gem source index for: [http://gems.rubyforge.org](http://gems.rubyforge.org)  
ERROR: While executing gem … (Gem::GemNotFoundException)  
Could not find net-ssh (\> 0) in any repository

So I wonder whether gem is intended to work at all under Cygwin. Anyone  
already tried this?

BTW, here is my Cygwin gem environment:

$ gem environment  
RubyGems Environment:

- VERSION: 0.9.3 (0.9.3)
- INSTALLATION DIRECTORY: /usr/lib/ruby/gems/1.8
- GEM PATH:
  - /usr/lib/ruby/gems/1.8

- REMOTE SOURCES:
  - [http://gems.rubyforge.org](http://gems.rubyforge.org)

---

<div class="post-metadata">

**Author:** ![ronaldfischer](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/67e7ee/32.png) [@ronaldfischer](https://www.ruby-forum.com/u/ronaldfischer)\
**Post date:** [May 14, 2007, 6:22pm UTC](https://www.ruby-forum.com/t/gem-under-cygwin-is-it-supposed-to-work/104141/2 "2007-05-14T18:22:27Z")

</div>

On 5/14/07, Ronald F. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> message, but left me  
> Could not find net-ssh (\> 0) in any repository
> 
> - INSTALLATION DIRECTORY: /usr/lib/ruby/gems/1.8

Try gem install -r net-ssh to install from a remote repository.

---

<div class="post-metadata">

**Author:** ![ronaldfischer](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/67e7ee/32.png) [@ronaldfischer](https://www.ruby-forum.com/u/ronaldfischer)\
**Post date:** [May 14, 2007, 6:29pm UTC](https://www.ruby-forum.com/t/gem-under-cygwin-is-it-supposed-to-work/104141/3 "2007-05-14T18:29:29Z")

</div>

> Try gem install -r net-ssh to install from a remote repository.

Thank you - this worked indeed!

Of course I now wonder why the installation under pure Windows was able  
to  
locate the net-ssh package without having me specified the “-r”  
option…  
(I actually never had used -r before in my gem installations).

Ronald
