# TMail problem

**URL:** <https://www.ruby-forum.com/t/tmail-problem/131279>\
**Category:** Ruby\
**Created:** [March 7, 2008, 4:35pm UTC](https://www.ruby-forum.com/t/tmail-problem/131279 "2008-03-07T16:35:54Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Simon\_Jones](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/54ee81/32.png) [@Simon\_Jones](https://www.ruby-forum.com/u/Simon_Jones)\
**Post date:** [March 7, 2008, 4:35pm UTC](https://www.ruby-forum.com/t/tmail-problem/131279/1 "2008-03-07T16:35:54Z")

</div>

Hi all,

I’ve written a Ruby script on Windows that makes use of the mysql and  
tmail  
gems. After a bit of hacking around (I’m still very new to Ruby) it  
seems to  
be doing what I want, so moved on to stage 2 of what I want to do -  
transfer  
the script to a box running Ubuntu server (7.04 IIRC).

I installed Ruby 1.8 and RubyGems on the Ubuntu box without any  
problems. I  
had a some difficulty getting the mysql gem installed, but that seems to  
be  
sorted now, and installing tmail seemed to go without a hitch -  
certainly,  
gem list --local gives:

mysql (2.7)  
MySQL/Ruby provides the same functions for Ruby programs that the  
MySQL C API provides for C programs.

sources (0.0.1)  
This package provides download sources for remote gem installation

tmail (1.2.1)  
Ruby Mail Handler

But, when I try to run the script by:

ruby getfeed1.rb I get:

getfeed1.rb:3:in `require’: no such file to load – tmail (LoadError)  
from getfeed1.rb:3

The same happens with any script (that I’ve tried) that requires tmail.  
I’m  
as new to Linux as I am to Ruby, so it may well be that I’m overlooking  
something really, really obvious here.

Any suggestions would be much appreciated!

TIA

Simon Jones.

---

<div class="post-metadata">

**Author:** ![Simon\_Jones](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/54ee81/32.png) [@Simon\_Jones](https://www.ruby-forum.com/u/Simon_Jones)\
**Post date:** [March 7, 2008, 6:01pm UTC](https://www.ruby-forum.com/t/tmail-problem/131279/2 "2008-03-07T18:01:28Z")

</div>

“Simon Jones” [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote in message  
news:2edAj.5799$removed\_email\_address@domain.invalid…

> getfeed1.rb:3:in `require’: no such file to load – tmail (LoadError)  
> from getfeed1.rb:3
> 
> The same happens with any script (that I’ve tried) that requires tmail.  
> I’m as new to Linux as I am to Ruby, so it may well be that I’m  
> overlooking something really, really obvious here.

Sorry to follow up my own post, but I’ve found (thanks to Tim H.'s  
post  
“requiring rubygems”) that

require ‘rubgems’

seems to solve the problem.

Simon

---

<div class="post-metadata">

**Author:** ![Simon\_Jones](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/54ee81/32.png) [@Simon\_Jones](https://www.ruby-forum.com/u/Simon_Jones)\
**Post date:** [March 7, 2008, 7:06pm UTC](https://www.ruby-forum.com/t/tmail-problem/131279/3 "2008-03-07T19:06:25Z")

</div>

On Mar 7, 10:34 am, “Simon Jones” [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> gem list --local gives:
> 
> Any suggestions would be much appreciated!

There was a missing attribute in the gem. Try the new 1.2.2 version.

T.
