From: "François Beausoleil" Date: 2008-02-21T05:03:43+09:00 Subject: Re: How to get the directory of the current script? Hi, File.dirname(__FILE__) will give you the current file's path. For your second question, there's no way to do that, unless your code follows strict code conventions (a-la Rails), or the module provides a way to query that information. Hope that helps ! François 2008/2/20, laredotornado : > Hi, > > How do I get the directory path of the file that is currently > executing? > > Also, if I have a module, within a function, how do I get the parent > directory (full path) of that module? > > Thanks, - Dave > > -- François Beausoleil http://blog.teksol.info/ http://piston.rubyforge.org/