From: Joel VanderWerf Date: 2005-09-15T08:17:30+09:00 Subject: Re: Launch directory in Rake Jim Freeze wrote: > I guess to put it succinctly, is that I want to use Rakefile > such that I have a single Rakefile for multiple projects > and I am working in one of the project directories. NOT > the case where I have a single Rakefile for a project with > multiple directories and I am working in one of the project > subdirectories. > > In the latter, the Rakefile can be more knowledgable, in > the former, the Rakefile needs to be told what directory > is being worked in. Can I pop into this thread even if I am not a Jim? Now I understand why your request makes sense--multiple projects that use the same rakefile. One way to handle this is to use require. Have a very simple "stub" rakefile in each project that just requires or loads a generic rakefile. That way, the current dir is inherited from the stub, but you have all the tasks defined in the generic rakefile. This seems less fragile than having to keep track of a launch_dir separately from the dir of the makefile. Btw, I really like the fact that you can run rake from any subdir of the project. -- vjoel : Joel VanderWerf : path berkeley edu : 510 665 3407