From: Patrick Hurley Date: 2006-07-11T14:55:14+09:00 Subject: Re: Platform Independence Programming On 7/11/06, Minkoo Seo wrote: > programs. That being the case, how can I rewrite the following program > in platform independent way? > > print "Hello\r\n" puts "Hello" > Dir["/tmp/*"] # note your code works fine under windows assuming you have a /tmp directory tmp_path = ENV['TEMP'] || ENV['TMP'] || File.join('','tmp') Dir[File.join(tmp_path,'*')] > And I also wonder whether there's another problem related to platform > independence. Plenty :-), fork/process handling, services / daemons, drive letters/mount points, IPC/pipes, etc. It really depends upon your needs/goals many things are pretty easy, some are very difficult you need to be more specific. Good luck pth