From: Ezra Zygmuntowicz Date: 2006-08-09T10:21:55+09:00 Subject: Re: Question on how to source a file with variables in it. On Aug 8, 2006, at 5:46 PM, Oscar Gon wrote: > I meant: > >> url = 'http://www.anydomain.com' >> contact = 'Joe' >> contactlast = 'Smith' >> > > -- > Posted via http://www.ruby-forum.com/. > The only way to do it with plain old local variables that I know of is to use eval. def load_vars(filname) eval(File.open(filename).read) end -Ezra