From: "Jakub PavlĂ­k jn." Date: 2009-01-15T06:40:11+09:00 Subject: Re: look at code in a gem > Hi everyone. I'm new to Ruby and have a question that I hope is > simple. I wanted to compare some strings for similarity, and found > this ruby gem called "english" (http://english.rubyforge.org/) which > has a method called "similarity" that gives me back a similarity score > when used. I wanted to know how that score is being calculated - and > I looked through the docs and couldn't find it. > > I'm wondering if there's a way to easily "see" the code for a > particular method from a gem - can i somehow use irb to show me the > code for "similarity" to see how it is coming up with that score? > > Thanks, and sorry if this is a silly newbie question. > > Type gem unpack english It will unpack the gem into cwd and you can search the code. -- "Configure complete, now type 'make' and PRAY." (configure script of zsnes - www.zsnes.com)