From: Chad Perrin Date: 2008-03-22T08:22:30+09:00 Subject: Re: getting the user's home directory path On Fri, Mar 21, 2008 at 06:16:02AM +0900, Nobuyoshi Nakada wrote: > Hi, > > At Thu, 20 Mar 2008 16:05:12 +0900, > Chad Perrin wrote in [ruby-talk:295141]: > > I've got a program that needs to access a file in the ~/etc/ directory. > > This program currently accesses it like so: > > > > file_path = File.expand_path("~#{ENV['USER']}/etc/#{filename}") > > File.expand_path("~/etc/#{filename}") Amazing -- and confusing. I could swear I actually tried that and it didn't work out for me. I guess I must have dreamed that. -- CCD CopyWrite Chad Perrin [ http://ccd.apotheon.org ] Phillip J. Haack: "Productivity is not about speed. It's about velocity. You can be fast, but if you're going in the wrong direction, you're not helping anyone."