# How to check if gems is installed

**URL:** <https://www.ruby-forum.com/t/how-to-check-if-gems-is-installed/123908>\
**Category:** Rails\
**Created:** [December 21, 2007, 10:34pm UTC](https://www.ruby-forum.com/t/how-to-check-if-gems-is-installed/123908 "2007-12-21T22:34:14Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![alex-osu3](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/13edae/32.png) [@alex-osu3](https://www.ruby-forum.com/u/alex-osu3)\
**Post date:** [December 21, 2007, 10:34pm UTC](https://www.ruby-forum.com/t/how-to-check-if-gems-is-installed/123908/1 "2007-12-21T22:34:14Z")

</div>

Hi all,

I use one-click installer to install ruby, together with gems under my  
vista box.  
I can type “ruby -v” from any directory and the promt windows shows  
ruby 1.8.6 after setting the enviroment variables. But I can only check  
“gems --version” in this directory c:\ruby\bin. Is it possible to check  
“gems --version” from other directories? and how?

thank you very much,  
Li

---

<div class="post-metadata">

**Author:** ![alex-osu3](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/13edae/32.png) [@alex-osu3](https://www.ruby-forum.com/u/alex-osu3)\
**Post date:** [December 22, 2007, 10:25am UTC](https://www.ruby-forum.com/t/how-to-check-if-gems-is-installed/123908/2 "2007-12-22T10:25:22Z")

</div>

Try gem --version, not gems.

On Dec 22, 2007 8:04 AM, Li Chen [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> ## thank you very much, Li
> 
> Posted via [http://www.ruby-forum.com/](http://www.ruby-forum.com/).
> 
> >

–  
Ryan B.

> **[frozenplague.net](http://www.frozenplague.net)**
>
> This domain may be for sale!

---

<div class="post-metadata">

**Author:** ![alex-osu3](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/13edae/32.png) [@alex-osu3](https://www.ruby-forum.com/u/alex-osu3)\
**Post date:** [December 23, 2007, 10:08pm UTC](https://www.ruby-forum.com/t/how-to-check-if-gems-is-installed/123908/3 "2007-12-23T22:08:37Z")

</div>

Ryan B. wrote:

> Try gem --version, not gems.  
> Ryan B.  
> [http://www.frozenplague.net](http://www.frozenplague.net)

It doesn’t work either.

Li

---

<div class="post-metadata">

**Author:** ![alex-osu3](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/13edae/32.png) [@alex-osu3](https://www.ruby-forum.com/u/alex-osu3)\
**Post date:** [December 23, 2007, 11:46pm UTC](https://www.ruby-forum.com/t/how-to-check-if-gems-is-installed/123908/4 "2007-12-23T23:46:14Z")

</div>

Then you might not have the ruby folder on the PATH variable in windows.

Right-click My Computer → Properties → Advanced → Environment  
Variables  
and add the path to ruby at the end of the PATH.  
On Dec 24, 2007 7:38 AM, Li Chen [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> Posted via [http://www.ruby-forum.com/](http://www.ruby-forum.com/).
> 
> >

–  
Ryan B.

> **[frozenplague.net](http://www.frozenplague.net)**
>
> This domain may be for sale!

Feel free to add me to MSN and/or GTalk as this email.

---

<div class="post-metadata">

**Author:** ![alex-osu3](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/13edae/32.png) [@alex-osu3](https://www.ruby-forum.com/u/alex-osu3)\
**Post date:** [December 24, 2007, 4:42pm UTC](https://www.ruby-forum.com/t/how-to-check-if-gems-is-installed/123908/5 "2007-12-24T16:42:10Z")

</div>

Ryan B. wrote:

> Then you might not have the ruby folder on the PATH variable in windows.
> 
> Right-click My Computer → Properties → Advanced → Environment  
> Variables  
> and add the path to ruby at the end of the PATH.
> 
> > Ryan B.  
> > [http://www.frozenplague.net](http://www.frozenplague.net)

I have no problem check ruby version and gem version from any directory  
when I install Ruby on window XP after I add the path to the system  
environment. But I now I follow the same method to install Ruby on  
Vista. I can check ruby version from any directory after adding the path  
to the system environment variable BUT NOT that of gem. I went to gems’  
website, which suggests to add RUBYOPT variable with value as rubygems.  
I follow it and it doesn’t work either.

I wonder if there is some compatibility Ruby with Vista.

Thanks,

Li
